summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-05-12 07:28:16 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-05-12 07:28:16 +0000
commit84eca25a328b2ae05b68b5cf4dd9b8bad2ab4647 (patch)
treea9f7ebb1a8fd54deb6f0b162e356b28de9c4d23b /test
parentbdbbf18c4a93547fbd648f405ec4f19f943124f8 (diff)
* io.c (rb_io_eof, remain_size, read_all, io_read, appendline)
(swallow, rb_io_each_byte, rb_io_getc): don't rely EOF flag. [ruby-talk:141527] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/ut_eof.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/ruby/ut_eof.rb b/test/ruby/ut_eof.rb
index e6f6edd..b7219dd 100644
--- a/test/ruby/ut_eof.rb
+++ b/test/ruby/ut_eof.rb
@@ -6,8 +6,8 @@ module TestEOF
assert_equal("", f.read(0))
assert_equal("", f.read(0))
assert_equal("", f.read)
- assert_nil(f.read(0))
- assert_nil(f.read(0))
+ assert_equal("", f.read(0))
+ assert_equal("", f.read(0))
}
open_file("") {|f|
assert_nil(f.read(1))
@@ -43,8 +43,8 @@ module TestEOF
assert_equal("" , f.read(0))
assert_equal("" , f.read(0))
assert_equal("", f.read)
- assert_nil(f.read(0))
- assert_nil(f.read(0))
+ assert_equal("", f.read(0))
+ assert_equal("", f.read(0))
}
open_file("a") {|f|
assert_equal("a", f.read(1))
@@ -69,7 +69,7 @@ module TestEOF
}
open_file("a") {|f|
assert_equal("a", f.read)
- assert_nil(f.read(0))
+ assert_equal("", f.read(0))
}
open_file("a") {|f|
s = "x"
@@ -109,7 +109,7 @@ module TestEOF
assert_equal(10, f.pos)
assert_equal("", f.read(0))
assert_equal("", f.read)
- assert_nil(f.read(0))
+ assert_equal("", f.read(0))
assert_equal("", f.read)
}
end