diff options
Diffstat (limited to 'test/ruby/test_process.rb')
-rw-r--r-- | test/ruby/test_process.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb index 75657ab894..ccd5676171 100644 --- a/test/ruby/test_process.rb +++ b/test/ruby/test_process.rb @@ -1237,8 +1237,9 @@ class TestProcess < Test::Unit::TestCase IO.pipe do |r, w| pid = spawn(RUBY, "foo", out: w) w.close - Thread.new { r.read(1); Process.kill(:SIGQUIT, pid) } + th = Thread.new { r.read(1); Process.kill(:SIGQUIT, pid) } Process.wait(pid) + th.join end t = Time.now s = $? |