aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases
diff options
context:
space:
mode:
authorYves Senn <yves.senn@gmail.com>2014-10-16 11:48:07 +0200
committerYves Senn <yves.senn@gmail.com>2014-10-16 11:56:50 +0200
commitd4d03a520dff836d54f794f7c644f2f5c952b01b (patch)
treeade3ddaca93169f0f3df9afc276421668d0db5d1 /activerecord/test/cases
parentf18a4d07eff6f20871d0e7c48d28d5a9f744a487 (diff)
downloadrails-d4d03a520dff836d54f794f7c644f2f5c952b01b.tar.gz
rails-d4d03a520dff836d54f794f7c644f2f5c952b01b.tar.bz2
rails-d4d03a520dff836d54f794f7c644f2f5c952b01b.zip
test, better describe `SerializationTypeMismatch` behavior. refs #14716.
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r--activerecord/test/cases/serialized_attribute_test.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/activerecord/test/cases/serialized_attribute_test.rb b/activerecord/test/cases/serialized_attribute_test.rb
index c5fb491b10..46d4da53df 100644
--- a/activerecord/test/cases/serialized_attribute_test.rb
+++ b/activerecord/test/cases/serialized_attribute_test.rb
@@ -140,11 +140,10 @@ class SerializedAttributeTest < ActiveRecord::TestCase
assert_equal 1, Topic.where(:content => nil).count
end
- def test_serialized_attribute_should_raise_exception_on_save_with_wrong_type
+ def test_serialized_attribute_should_raise_exception_on_assignment_with_wrong_type
Topic.serialize(:content, Hash)
assert_raise(ActiveRecord::SerializationTypeMismatch) do
topic = Topic.new(content: 'string')
- topic.save
end
end