summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-25 14:46:01 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-25 14:46:01 +0000
commitf935d5f4f6eb3c9241ff94b2237fb022a350413b (patch)
tree1a2a5e7dd9a54fecd7aa3491e4a5ab5d1d6b82c3 /test
parent0cfb043b45aca903a6a42002faa91e106ad8247d (diff)
* test/ruby/test_m17n.rb (TestM17N#test_sprintf_s):
added an assertion for [ruby-list:46274]. see also r24506. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_1@25476 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_m17n.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/ruby/test_m17n.rb b/test/ruby/test_m17n.rb
index afea18eabb..d8dcde5cac 100644
--- a/test/ruby/test_m17n.rb
+++ b/test/ruby/test_m17n.rb
@@ -11,6 +11,7 @@ class TestM17N < Test::Unit::TestCase
def e(str) str.dup.force_encoding("EUC-JP") end
def s(str) str.dup.force_encoding("Windows-31J") end
def u(str) str.dup.force_encoding("UTF-8") end
+ def ua(str) str.dup.force_encoding("US-ASCII") end
end
include AESU
extend AESU
@@ -807,6 +808,8 @@ class TestM17N < Test::Unit::TestCase
assert_strenc("\x00", 'Windows-31J', s("%s") % s("\x00"))
assert_strenc("\x00", 'UTF-8', u("%s") % u("\x00"))
assert_equal("EUC-JP", (e("\xc2\xa1 %s") % "foo").encoding.name)
+
+ assert_equal("EUC-JP", (e("%s: %s: %s") % [ua("abc"), u("a"), e("\xc2\xa1")]).encoding.name, "[ruby-list:46274]")
end
def test_str_lt