[前][次][番号順一覧][スレッド一覧]

ruby-changes:7362

From: akr <ko1@a...>
Date: Wed, 27 Aug 2008 22:39:36 +0900 (JST)
Subject: [ruby-changes:7362] Ruby:r18881 (trunk): add a test.

akr	2008-08-27 22:39:25 +0900 (Wed, 27 Aug 2008)

  New Revision: 18881

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=18881

  Log:
    add a test.

  Modified files:
    trunk/test/ruby/test_io_m17n.rb

Index: test/ruby/test_io_m17n.rb
===================================================================
--- test/ruby/test_io_m17n.rb	(revision 18880)
+++ test/ruby/test_io_m17n.rb	(revision 18881)
@@ -826,6 +826,14 @@
     }
   end
 
+  def test_read_stateful
+    with_pipe("euc-jp:iso-2022-jp") {|r, w|
+      w << "\xA4\xA2"
+      w.close
+      assert_equal("\e$B$\"\e(B".force_encoding("iso-2022-jp"), r.read)
+    }
+  end
+
   def test_stdin_external_encoding_with_reopen
     with_tmpdir {
       open("tst", "w+") {|f|

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]