git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
duerst 2017-06-28 02:28:00 +00:00
Родитель ff36c25f47
Коммит b3f38b57e7
1 изменённых файлов: 3 добавлений и 0 удалений

Просмотреть файл

@ -1006,6 +1006,9 @@ class TestTranscode < Test::Unit::TestCase
fffd5 = "\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD".encode 'UTF-16BE'
fffd6 = "\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD\uFFFD".encode 'UTF-16BE'
assert_equal fffd1, "\x80".encode("utf-16be", "utf-8", invalid: :replace)
assert_equal fffd1, "\xBF".encode("utf-16be", "utf-8", invalid: :replace)
assert_equal fffd2, "\xC0\x80".encode("utf-16be", "utf-8", invalid: :replace)
assert_equal fffd2, "\xC0\xBF".encode("utf-16be", "utf-8", invalid: :replace)
assert_equal fffd2, "\xC1\x80".encode("utf-16be", "utf-8", invalid: :replace)