diff --git a/test/ruby/test_transcode.rb b/test/ruby/test_transcode.rb index e88979a681..db91010c94 100644 --- a/test/ruby/test_transcode.rb +++ b/test/ruby/test_transcode.rb @@ -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