diff options
-rw-r--r-- | test/ruby/test_io_m17n.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/ruby/test_io_m17n.rb b/test/ruby/test_io_m17n.rb index 2e52c8bb3e..dc10d1d29c 100644 --- a/test/ruby/test_io_m17n.rb +++ b/test/ruby/test_io_m17n.rb @@ -417,5 +417,14 @@ EOT assert_equal(data, result) } end + + def test_gets_nil + with_pipe("UTF-8:EUC-JP") {|r, w| + w << "\u{3042}" + w.close + result = r.gets(nil) + assert_equal("\u{3042}".encode("euc-jp"), result) + } + end end |