summaryrefslogtreecommitdiffstats
path: root/test/ruby/test_econv.rb
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-03 11:09:25 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-03 11:09:25 +0000
commitf55f5b7a8d6db047f3f41ff7f51b329187cdbeb1 (patch)
tree877255a1972376efd01492a1a18ef22636fcf94e /test/ruby/test_econv.rb
parent92de528258bf8e2091ca618d96cb35b1559ce3dc (diff)
downloadruby-f55f5b7a8d6db047f3f41ff7f51b329187cdbeb1.tar.gz
ruby-f55f5b7a8d6db047f3f41ff7f51b329187cdbeb1.tar.xz
ruby-f55f5b7a8d6db047f3f41ff7f51b329187cdbeb1.zip
* enc/trans/japanese.trans: new file.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_econv.rb')
-rw-r--r--test/ruby/test_econv.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_econv.rb b/test/ruby/test_econv.rb
index 3e2814bff..374834bd3 100644
--- a/test/ruby/test_econv.rb
+++ b/test/ruby/test_econv.rb
@@ -385,6 +385,12 @@ class TestEncodingConverter < Test::Unit::TestCase
def test_errinfo_invalid_euc_jp
ec = Encoding::Converter.new("EUC-JP", "Shift_JIS")
ec.primitive_convert(src="\xff", dst="", nil, 10)
+ assert_errinfo(:invalid_byte_sequence, "EUC-JP", "Shift_JIS", "\xFF", "", ec)
+ end
+
+ def test_errinfo_invalid_euc_jp2
+ ec = Encoding::Converter.new("EUC-JP", "ISO-8859-1")
+ ec.primitive_convert(src="\xff", dst="", nil, 10)
assert_errinfo(:invalid_byte_sequence, "EUC-JP", "UTF-8", "\xFF", "", ec)
end