summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-12-23 00:24:52 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-12-23 00:24:52 +0000
commit8beb0d358782c08d8b529c7ba655b196573328f4 (patch)
tree1de21a41d547ef44b586631fe0eb44352e34e2dc /test
parentb32f79e0db67f12d3f11ba76a304034f409e7422 (diff)
* test/test_pty.rb (test_pty_check_default): call PTY.check until
"cat" command is finished. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34106 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/test_pty.rb7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/test_pty.rb b/test/test_pty.rb
index 6236e7c6272..122fb6c13bd 100644
--- a/test/test_pty.rb
+++ b/test/test_pty.rb
@@ -172,12 +172,13 @@ class TestPTY < Test::Unit::TestCase
st1 = PTY.check(pid)
w.close
r.close
- sleep(0.1)
- st2 = PTY.check(pid)
+ begin
+ sleep(0.1)
+ end until st2 = PTY.check(pid)
end
assert_equal(pid, st1.pid) if st1
assert_nil(st1)
- assert_equal(pid, st2.pid) if st2
+ assert_equal(pid, st2.pid)
end
def test_pty_check_raise