summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-09-02 13:32:59 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-09-02 13:32:59 +0000
commit6bd80ffc2277eca027075c4f209feb92cf5c501e (patch)
treec8fea2c413b5316fce54c22eecd4482c9d769dd1 /test
parent1a37c5a4b624e587d7194c4326d7a1a073576aa5 (diff)
test_io.rb: ignore stream closed IOError
* test/ruby/test_io.rb (test_readpartial_locktmp): stream closed IOError while reading is not a matter. [Bug #10193] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47353 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_io.rb10
1 files changed, 7 insertions, 3 deletions
diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb
index 5f5a21b3cb..95331ba02d 100644
--- a/test/ruby/test_io.rb
+++ b/test/ruby/test_io.rb
@@ -2867,15 +2867,19 @@ End
Thread.pass until th.stop?
buf.replace("")
assert_empty(buf, bug6099)
- th.join rescue ($@.concat(caller); raise) unless th.alive?
+ assert_predicate(th, :alive?)
w.write(data)
Thread.pass while th.alive?
- th.join rescue ($@.concat(caller); raise)
end
assert_equal(data, buf, bug6099)
rescue RuntimeError # can't modify string; temporarily locked
ensure
- th.join if th
+ if th
+ begin
+ th.join
+ rescue IOError
+ end
+ end
end
def test_advise_pipe