diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-21 21:35:08 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-21 21:35:08 +0000 |
commit | 5a1cf1c5cb2dd1007389a5c3f2ef5bcecc74a6ac (patch) | |
tree | d25e76373c237f8c71b2e3c018c6d5e04f36a21f /bootstraptest/test_io.rb | |
parent | ac42f7adf953fb6af1ac72cd07438b3ecefbea1c (diff) | |
download | ruby-5a1cf1c5cb2dd1007389a5c3f2ef5bcecc74a6ac.tar.gz |
* bootstraptest/test_fork.rb: skip if fork is not unsupported.
* bootstraptest/test_io.rb: skip if require failed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14446 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bootstraptest/test_io.rb')
-rw-r--r-- | bootstraptest/test_io.rb | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/bootstraptest/test_io.rb b/bootstraptest/test_io.rb index 20a441de9f..fa3654379f 100644 --- a/bootstraptest/test_io.rb +++ b/bootstraptest/test_io.rb @@ -9,17 +9,20 @@ assert_finish 5, %q{ }, '[ruby-dev:31866]' assert_finish 10, %q{ - require "io/nonblock" - r, w = IO.pipe - w.nonblock = true - w.write_nonblock("a" * 100000) - w.nonblock = false - t1 = Thread.new { w.write("b" * 4096) } - t2 = Thread.new { w.write("c" * 4096) } - sleep 0.5 - r.sysread(4096).length - sleep 0.5 - r.sysread(4096).length - t1.join - t2.join + begin + require "io/nonblock" + r, w = IO.pipe + w.nonblock = true + w.write_nonblock("a" * 100000) + w.nonblock = false + t1 = Thread.new { w.write("b" * 4096) } + t2 = Thread.new { w.write("c" * 4096) } + sleep 0.5 + r.sysread(4096).length + sleep 0.5 + r.sysread(4096).length + t1.join + t2.join + rescue LoadError + end }, '[ruby-dev:32566]' |