1 require File.expand_path(File.join(File.dirname(__FILE__), '..', 'test_helper'))
3 class DbFileTest < Test::Unit::TestCase
4 include BaseAttachmentTests
5 attachment_model Attachment
7 def test_should_call_after_attachment_saved(klass = Attachment)
8 attachment_model.saves = 0
10 upload_file :filename => '/files/rails.png'
12 assert_equal 1, attachment_model.saves
15 test_against_subclass :test_should_call_after_attachment_saved, Attachment