Fixing syntax on SerializerTest so that it grabs the object attributes in the same manner they are composed when PaperTrail serializes them in the :record_update and :record_destroy callbacks.

This commit is contained in:
Ben Atkins 2013-01-31 17:32:36 -05:00
parent e0771897a7
commit 0dbc6a8e33
1 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@ class SerializerTest < ActiveSupport::TestCase
END
@fluxor = Fluxor.create :name => 'Some text.'
@original_fluxor_attributes = @fluxor.attributes
@original_fluxor_attributes = @fluxor.send(:item_before_change).attributes # this is exactly what PaperTrail serializes
@fluxor.update_attributes :name => 'Some more text.'
end
@ -37,7 +37,7 @@ class SerializerTest < ActiveSupport::TestCase
END
@fluxor = Fluxor.create :name => 'Some text.'
@original_fluxor_attributes = @fluxor.attributes
@original_fluxor_attributes = @fluxor.send(:item_before_change).attributes # this is exactly what PaperTrail serializes
@fluxor.update_attributes :name => 'Some more text.'
end