diff options
author | Samuel Williams <samuel.williams@oriontransfer.co.nz> | 2022-10-07 21:48:38 +1300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-07 21:48:38 +1300 |
commit | e4f91bbdbaa6ab3125f24967414ac5300bb244f5 (patch) | |
tree | 575f8febdd50601522c5e5ec72f3436139304537 /test/ruby/test_io.rb | |
parent | e76217a7f3957c9cea52832c2f4237130411f7dd (diff) | |
download | ruby-e4f91bbdbaa6ab3125f24967414ac5300bb244f5.tar.gz |
Add IO#timeout attribute and use it for blocking IO operations. (#5653)
Diffstat (limited to 'test/ruby/test_io.rb')
-rw-r--r-- | test/ruby/test_io.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb index f791b4415d..f4ebccf9df 100644 --- a/test/ruby/test_io.rb +++ b/test/ruby/test_io.rb @@ -3960,6 +3960,9 @@ __END__ noex = Thread.new do # everything right and never see exceptions :) until sig_rd.wait_readable(0) IO.pipe do |r, w| + assert_nil r.timeout + assert_nil w.timeout + th = Thread.new { r.read(1) } w.write(dot) |