diff options
Diffstat (limited to 'activesupport/test/hash_with_indifferent_access_test.rb')
-rw-r--r-- | activesupport/test/hash_with_indifferent_access_test.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/activesupport/test/hash_with_indifferent_access_test.rb b/activesupport/test/hash_with_indifferent_access_test.rb index 843994147b..880457386e 100644 --- a/activesupport/test/hash_with_indifferent_access_test.rb +++ b/activesupport/test/hash_with_indifferent_access_test.rb @@ -7,4 +7,11 @@ class HashWithIndifferentAccessTest < ActiveSupport::TestCase hash.reverse_merge! key: :new_value assert_equal :old_value, hash[:key] end + + def test_frozen_value + value = [1, 2, 3].freeze + hash = {}.with_indifferent_access + hash[:key] = value + assert_equal hash[:key], value + end end
\ No newline at end of file |