diff options
author | kennyj <kennyj@gmail.com> | 2013-06-02 09:06:12 +0900 |
---|---|---|
committer | kennyj <kennyj@gmail.com> | 2013-06-02 10:26:04 +0900 |
commit | 6c74825beb548d897ba5c3ec32e65d6036a19cc9 (patch) | |
tree | 51a1a1abafb492cef4acac157b6dbbaa1c920ece | |
parent | 0a88c10e54f4e795856cf9ed6335b2a384b5c26f (diff) | |
download | rails-6c74825beb548d897ba5c3ec32e65d6036a19cc9.tar.gz rails-6c74825beb548d897ba5c3ec32e65d6036a19cc9.tar.bz2 rails-6c74825beb548d897ba5c3ec32e65d6036a19cc9.zip |
Remove instance level serialized_attributes setting was deprecated.
-rw-r--r-- | activerecord/lib/active_record/attribute_methods/serialization.rb | 7 | ||||
-rw-r--r-- | activerecord/test/cases/serialized_attribute_test.rb | 6 |
2 files changed, 0 insertions, 13 deletions
diff --git a/activerecord/lib/active_record/attribute_methods/serialization.rb b/activerecord/lib/active_record/attribute_methods/serialization.rb index 7f1ebab4cd..d326ef7c22 100644 --- a/activerecord/lib/active_record/attribute_methods/serialization.rb +++ b/activerecord/lib/active_record/attribute_methods/serialization.rb @@ -50,13 +50,6 @@ module ActiveRecord end end - # *DEPRECATED*: Use ActiveRecord::AttributeMethods::Serialization::ClassMethods#serialized_attributes class level method instead. - def serialized_attributes - message = "Instance level serialized_attributes method is deprecated, please use class level method." - ActiveSupport::Deprecation.warn message - defined?(@serialized_attributes) ? @serialized_attributes : self.class.serialized_attributes - end - class Type # :nodoc: def initialize(column) @column = column diff --git a/activerecord/test/cases/serialized_attribute_test.rb b/activerecord/test/cases/serialized_attribute_test.rb index 765e92ccca..b49c27bc78 100644 --- a/activerecord/test/cases/serialized_attribute_test.rb +++ b/activerecord/test/cases/serialized_attribute_test.rb @@ -19,12 +19,6 @@ class SerializedAttributeTest < ActiveRecord::TestCase assert_equal %w(content), Topic.serialized_attributes.keys end - def test_serialized_attributes_are_class_level_settings - topic = Topic.new - assert_raise(NoMethodError) { topic.serialized_attributes = [] } - assert_deprecated { topic.serialized_attributes } - end - def test_serialized_attribute Topic.serialize("content", MyObject) |