diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-31 07:59:03 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-31 07:59:03 +0000 |
commit | 2d71485ec1898c5c0f43d1c7e0fdb1f1442c9dd8 (patch) | |
tree | 7a7036d0da3815cfe3c3eb186022a0a94b794798 /test/ruby | |
parent | ca6a8b1e2c9e1832ab993edff48d2d3a9234a4b3 (diff) | |
download | ruby-2d71485ec1898c5c0f43d1c7e0fdb1f1442c9dd8.tar.gz |
* transcode.c (econv_putback): associate encoding to the result.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18986 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r-- | test/ruby/test_econv.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/ruby/test_econv.rb b/test/ruby/test_econv.rb index 1dc267d966..fd7bed5652 100644 --- a/test/ruby/test_econv.rb +++ b/test/ruby/test_econv.rb @@ -498,8 +498,8 @@ class TestEncodingConverter < Test::Unit::TestCase ec = Encoding::Converter.new("utf-16le", "euc-jp") ret = ec.primitive_convert(src="\x00\xd8\x21\x00", dst="", nil, nil) assert_equal(:invalid_byte_sequence, ret) - assert_equal("\x00", ec.putback(1)) - assert_equal("\x21", ec.putback(1)) + assert_equal("\x00".force_encoding("utf-16le"), ec.putback(1)) + assert_equal("\x21".force_encoding("utf-16le"), ec.putback(1)) assert_equal("", ec.putback(1)) end |