From 7b7ced744ac9a7e18c328bbf38ee2e49daf2fcb5 Mon Sep 17 00:00:00 2001 From: yugui Date: Tue, 3 Mar 2009 11:40:41 +0000 Subject: merges r22610 from trunk into ruby_1_9_1. -- * io.c (rb_io_getline_1): enables limit even if rs is given. [ruby-core:22434] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@22740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_io.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test/ruby/test_io.rb') diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb index 073ca2031..9082b76b6 100644 --- a/test/ruby/test_io.rb +++ b/test/ruby/test_io.rb @@ -61,8 +61,9 @@ class TestIO < Test::Unit::TestCase def test_gets_limit_extra_arg with_pipe {|r, w| r, w = IO.pipe - w << "0123456789" + w << "0123456789\n0123456789" w.close + assert_equal("0123456789\n0", r.gets(nil, 12)) assert_raise(TypeError) { r.gets(3,nil) } } end -- cgit