aboutsummaryrefslogtreecommitdiffstats
path: root/test/ruby/test_m17n.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_m17n.rb')
-rw-r--r--test/ruby/test_m17n.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/ruby/test_m17n.rb b/test/ruby/test_m17n.rb
index 7e343ab31f..bdde127840 100644
--- a/test/ruby/test_m17n.rb
+++ b/test/ruby/test_m17n.rb
@@ -1471,4 +1471,14 @@ class TestM17N < Test::Unit::TestCase
yield(*strs)
end
end
+
+ def test_str_b
+ s = "\u3042"
+ assert_equal(a("\xE3\x81\x82"), s.b)
+ assert_equal(Encoding::ASCII_8BIT, s.b.encoding)
+ s.taint
+ assert_equal(true, s.b.tainted?)
+ s.untrust
+ assert_equal(true, s.b.untrusted?)
+ end
end