aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-20 15:27:35 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-20 15:27:35 +0000
commitcfb91bc2f57050e853b330b5bf497fea4c19e0f4 (patch)
treee079fa6e038ce49b2289f80347f14fe48d8dff36 /test
parent5c04ed459bde261deff75a9d6f4fffee7d12dd58 (diff)
downloadruby-cfb91bc2f57050e853b330b5bf497fea4c19e0f4.tar.gz
* string.c (tr_trans): wrong encoding check for tree strings.
* test/ruby/test_m17n.rb (TestM17N::test_tr_s): "invalid mbstring sequence" is not an error to be tested. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14369 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_m17n.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/ruby/test_m17n.rb b/test/ruby/test_m17n.rb
index 8b06a2e07b..1923d9294e 100644
--- a/test/ruby/test_m17n.rb
+++ b/test/ruby/test_m17n.rb
@@ -1643,7 +1643,7 @@ class TestM17N < Test::Unit::TestCase
#puts "#{encdump s1}.tr_s(#{encdump s2}, #{encdump s3})"
t = s1.tr_s(s2, s3)
rescue ArgumentError
- e = $!
+ e = $! unless /mbstring sequence/ =~ $!.message
end
if e
encs = []
@@ -1651,7 +1651,7 @@ class TestM17N < Test::Unit::TestCase
encs << s2.encoding if !is_ascii_only?(s2)
encs << s3.encoding if !is_ascii_only?(s3)
encs.uniq!
- #p e, encs
+ #p e, encs,
assert(1 < encs.length, "#{encdump s1}.tr_s(#{encdump s2}, #{encdump s3})")
end
}