diff options
author | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2012-12-03 16:19:37 -0800 |
---|---|---|
committer | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2012-12-03 16:19:37 -0800 |
commit | e1ce84b1a95cfc6aac0ae904e6597f467f229eac (patch) | |
tree | 1713f13e298788591dff3c7f60b578c07af01b90 | |
parent | baa4d79cb101e7a65b0399b20eebd5dd5cce0cf1 (diff) | |
parent | 86dd2f32764ef3f141d9b24a47725b004fd4ac71 (diff) | |
download | rails-e1ce84b1a95cfc6aac0ae904e6597f467f229eac.tar.gz rails-e1ce84b1a95cfc6aac0ae904e6597f467f229eac.tar.bz2 rails-e1ce84b1a95cfc6aac0ae904e6597f467f229eac.zip |
Merge pull request #8393 from frodsan/fix_dependend_order_test_example
Ensure original encoding does not change in mb_chars test.
-rw-r--r-- | activesupport/test/multibyte_chars_test.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/activesupport/test/multibyte_chars_test.rb b/activesupport/test/multibyte_chars_test.rb index 0088a06c34..2bf73291a2 100644 --- a/activesupport/test/multibyte_chars_test.rb +++ b/activesupport/test/multibyte_chars_test.rb @@ -47,7 +47,10 @@ class MultibyteCharsTest < ActiveSupport::TestCase end def test_methods_are_forwarded_to_wrapped_string_for_byte_strings + original_encoding = BYTE_STRING.encoding assert_equal BYTE_STRING.length, BYTE_STRING.mb_chars.length + ensure + BYTE_STRING.force_encoding(original_encoding) end def test_forwarded_method_with_non_string_result_should_be_returned_vertabim |