diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-28 05:15:25 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-28 05:15:25 +0000 |
| commit | 5e18ae782dc162421f9b15b613894aaba7b23eae (patch) | |
| tree | f74a5d4ad73c3af9c3a04651b6523ba00b13b7b0 /test/ruby | |
| parent | c6501eca85dbdb3cb53bfd4bda67ba37373bda61 (diff) | |
| download | ruby-5e18ae782dc162421f9b15b613894aaba7b23eae.tar.gz ruby-5e18ae782dc162421f9b15b613894aaba7b23eae.tar.xz ruby-5e18ae782dc162421f9b15b613894aaba7b23eae.zip | |
add a test for [ruby-dev:34958].
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17622 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
| -rw-r--r-- | test/ruby/test_argf.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/ruby/test_argf.rb b/test/ruby/test_argf.rb index 82aaa41dc..63b278198 100644 --- a/test/ruby/test_argf.rb +++ b/test/ruby/test_argf.rb @@ -582,6 +582,16 @@ class TestArgf < Test::Unit::TestCase end end + def test_each_line_paragraph + EnvUtil.rubyexec('-e', 'ARGF.each_line("") {|para| p para}') do |w, r, e| + w << "a\n\nb\n" + w.close + assert_equal("\"a\\n\\n\"\n", r.gets, "[ruby-dev:34958]") + assert_equal("\"b\\n\"\n", r.gets) + assert_equal(nil, r.gets) + end + end + def test_each_byte ruby('-e', <<-SRC, @t1.path, @t2.path, @t3.path) do |f| s = [] |
