diff options
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/serialized_attribute_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/activerecord/test/cases/serialized_attribute_test.rb b/activerecord/test/cases/serialized_attribute_test.rb index c8441201ca..c261a5b1c0 100644 --- a/activerecord/test/cases/serialized_attribute_test.rb +++ b/activerecord/test/cases/serialized_attribute_test.rb @@ -264,4 +264,10 @@ class SerializedAttributeTest < ActiveRecord::TestCase assert_not topic.content_changed? end + + def test_classes_without_no_arg_constructors_are_not_supported + assert_raises(ArgumentError) do + Topic.serialize(:content, Regexp) + end + end end |