diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2014-05-13 08:04:24 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2014-05-13 08:04:24 -0700 |
commit | f0f7c4ff96ad8223430e9ee13ca1bb25732e13e7 (patch) | |
tree | 1d2b61652037eeac779672e662c290d6ad02c62e /actionview/test | |
parent | 6470f374c98e893f460e0db29ad1d535fe028794 (diff) | |
parent | 6caf3ab51b422e08135cbfbdaeedb94b1f6c312c (diff) | |
download | rails-f0f7c4ff96ad8223430e9ee13ca1bb25732e13e7.tar.gz rails-f0f7c4ff96ad8223430e9ee13ca1bb25732e13e7.tar.bz2 rails-f0f7c4ff96ad8223430e9ee13ca1bb25732e13e7.zip |
Merge pull request #15068 from josepjaume/patch-1
Dup options hash to prevent modifications
Diffstat (limited to 'actionview/test')
-rw-r--r-- | actionview/test/template/translation_helper_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/actionview/test/template/translation_helper_test.rb b/actionview/test/template/translation_helper_test.rb index c4770840fb..f166668a60 100644 --- a/actionview/test/template/translation_helper_test.rb +++ b/actionview/test/template/translation_helper_test.rb @@ -151,4 +151,10 @@ class TranslationHelperTest < ActiveSupport::TestCase translation = translate(:'translations.missing', default: ['A Generic String', 'Second generic string']) assert_equal 'A Generic String', translation end + + def test_translate_doesnt_change_options + options = {} + translate(:'translations.missing', options) + assert_equal options, {} + end end |