diff options
author | Kir Shatrov <shatrov@me.com> | 2015-03-20 21:33:26 +0200 |
---|---|---|
committer | Kir Shatrov <shatrov@me.com> | 2015-03-20 23:06:17 +0200 |
commit | d5bddc1b2d3d794b2eddcb7309f41f87a8d665c1 (patch) | |
tree | bc6f85e2703e76a1304aef6883e571a5949055d8 /activesupport/test/core_ext/marshal_test.rb | |
parent | b19990c82c6a9beff0cd058dc2ff67894a2f9ea7 (diff) | |
download | rails-d5bddc1b2d3d794b2eddcb7309f41f87a8d665c1.tar.gz rails-d5bddc1b2d3d794b2eddcb7309f41f87a8d665c1.tar.bz2 rails-d5bddc1b2d3d794b2eddcb7309f41f87a8d665c1.zip |
Use Module#prepend instead of alias_method_chain
Thanks @fbernier for suggestion! <3
At this moment we can use Module#prepend in all all cases
except of Range because of the bug [1] in MRI 2.2
[1] https://bugs.ruby-lang.org/issues/10847
Diffstat (limited to 'activesupport/test/core_ext/marshal_test.rb')
-rw-r--r-- | activesupport/test/core_ext/marshal_test.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/test/core_ext/marshal_test.rb b/activesupport/test/core_ext/marshal_test.rb index 8f3f710dfd..e49330128b 100644 --- a/activesupport/test/core_ext/marshal_test.rb +++ b/activesupport/test/core_ext/marshal_test.rb @@ -15,7 +15,7 @@ class MarshalTest < ActiveSupport::TestCase sanity_data = ["test", [1, 2, 3], {a: [1, 2, 3]}, ActiveSupport::TestCase] sanity_data.each do |obj| dumped = Marshal.dump(obj) - assert_equal Marshal.load_without_autoloading(dumped), Marshal.load(dumped) + assert_equal Marshal.method(:load).super_method.call(dumped), Marshal.load(dumped) end end @@ -121,4 +121,4 @@ class MarshalTest < ActiveSupport::TestCase end end end -end
\ No newline at end of file +end |