mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
test_transcode.rb: base encoding
* test/ruby/test_transcode.rb (TestTranscode#test_pseudo_encoding_inspect): test for proper base encoding. [ruby-core:57318] [Bug #8940] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43024 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
3a2aca5075
commit
e29c3bfb9f
1 changed files with 1 additions and 0 deletions
|
@ -2068,6 +2068,7 @@ class TestTranscode < Test::Unit::TestCase
|
|||
%w[UTF-32 UTF-16].each do |enc|
|
||||
define_method("test_pseudo_encoding_inspect(#{enc})") do
|
||||
assert_normal_exit("'aaa'.encode('#{enc}').inspect", bug8940)
|
||||
assert_equal(4, 'aaa'.encode(enc).length, "should count in #{enc} with BOM")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue