summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/ruby/test_m17n.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/test_m17n.rb b/test/ruby/test_m17n.rb
index 4e4e91e12c..6cffcdd4f1 100644
--- a/test/ruby/test_m17n.rb
+++ b/test/ruby/test_m17n.rb
@@ -297,6 +297,10 @@ class TestM17N < Test::Unit::TestCase
end
def test_utf16
+ s1 = "aa".force_encoding("utf-16be")
+ s2 = "z".force_encoding("us-ascii")
+ assert_nil(Encoding.compatible?(s1, s2), "Encoding.compatible?(#{encdump s1}, #{encdump s2})")
+
s1 = "ab".force_encoding("utf-16be")
s2 = "b".force_encoding("utf-16be")
assert_equal(false, s1.end_with?(s2), "#{encdump s1}.end_with?(#{encdump s2})")