Sha256: bb0c56c18e5cca1cedb5f151dbcb15baab3ba0dbc39fff0e024903c4f39e3fc4
Contents?: true
Size: 543 Bytes
Versions: 2
Compression:
Stored size: 543 Bytes
Contents
require "test_helper" class IntegrationTest < Minitest::Should::TestCase setup do @file = fixture_file("ruby.png") end should "create attachment and its files" do dummy = Dummy.create!(avatar: @file) assert File.file?(dummy.avatar.path), "File was not uploaded" end should "delete attachment and its files" do dummy = Dummy.create!(avatar: @file) avatar = dummy.avatar.path dummy.destroy assert !File.file?(avatar), "File was not deleted" end teardown do @file.close cleanup end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
paperclip-sftp-1.0.5 | test/integration_test.rb |
paperclip-sftp-1.0.4 | test/integration_test.rb |