Sha256: 3da85fe1541d73099e5321c5a6e00e3f3c1a2a107a26f77b805669629355a00c

Contents?: true

Size: 596 Bytes

Versions: 72

Compression:

Stored size: 596 Bytes

Contents

require './test/helper'

class HaveAttachedFileMatcherTest < Test::Unit::TestCase
  context "have_attached_file" do
    setup do
      @dummy_class = reset_class "Dummy"
      reset_table "dummies"
      @matcher     = self.class.have_attached_file(:avatar)
    end

    context "given a class with no attachment" do
      should_reject_dummy_class
    end

    context "given a class with an attachment" do
      setup do
        modify_table("dummies"){|d| d.string :avatar_file_name }
        @dummy_class.has_attached_file :avatar
      end

      should_accept_dummy_class
    end
  end
end

Version data entries

72 entries across 72 versions & 17 rubygems

Version Path
paperclip-3.1.1 test/matchers/have_attached_file_matcher_test.rb
paperclip-3.1.0 test/matchers/have_attached_file_matcher_test.rb
paperclip-3.0.4 test/matchers/have_attached_file_matcher_test.rb
paperclip-3.0.3 test/matchers/have_attached_file_matcher_test.rb
cloudfuji_paperclip-3.0.3 test/matchers/have_attached_file_matcher_test.rb
cloudfuji_paperclip-2.4.6 test/matchers/have_attached_file_matcher_test.rb
paperclip-3.0.2 test/matchers/have_attached_file_matcher_test.rb
radiant-1.0.0 ruby-debug/ruby/1.8/gems/paperclip-2.3.16/test/matchers/have_attached_file_matcher_test.rb
paperclip-2.7.0 test/matchers/have_attached_file_matcher_test.rb
paperclip-2.6.0 test/matchers/have_attached_file_matcher_test.rb
paperclip-2.5.2 test/matchers/have_attached_file_matcher_test.rb
paperclip-2.5.1 test/matchers/have_attached_file_matcher_test.rb
smarter_paperclip-0.3.0 test/matchers/have_attached_file_matcher_test.rb
paperclip-2.5.0 test/matchers/have_attached_file_matcher_test.rb
mender_paperclip-2.4.3.1 test/matchers/have_attached_file_matcher_test.rb
cemeng-paperclip-2.3.6 test/matchers/have_attached_file_matcher_test.rb
jmcnevin-paperclip-2.4.5.1 test/matchers/have_attached_file_matcher_test.rb
jmcnevin-paperclip-2.4.5 test/matchers/have_attached_file_matcher_test.rb
paperclip-2.4.5 test/matchers/have_attached_file_matcher_test.rb
mender_paperclip-2.4.3 test/matchers/have_attached_file_matcher_test.rb