aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-06-30 08:38:36 +0000
committernormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-06-30 08:38:36 +0000
commita3a325e5a321d0c8f5f80e9cabfd02b3e8839c81 (patch)
tree3bda89c3eb86c57d913e795786d723707e0d86cf
parentb6bd6b5379032b647e2fa9ba552b8be98a9031cd (diff)
downloadruby-a3a325e5a321d0c8f5f80e9cabfd02b3e8839c81.tar.gz
fix r63799 ("test/ruby/test_rubyoptions.rb: improve diagnostics for failures")
CI machines are faster than mine :x git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63802 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_rubyoptions.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/ruby/test_rubyoptions.rb b/test/ruby/test_rubyoptions.rb
index 27a24f0764..edd44ca0ae 100644
--- a/test/ruby/test_rubyoptions.rb
+++ b/test/ruby/test_rubyoptions.rb
@@ -591,7 +591,8 @@ class TestRubyOptions < Test::Unit::TestCase
pid = spawn(EnvUtil.rubybin, "test-script")
ps = nil
- stop = Process.clock_gettime(Process::CLOCK_MONOTONIC) + 30
+ now = Process.clock_gettime(Process::CLOCK_MONOTONIC)
+ stop = now + 30
begin
sleep 0.1
ps = `#{PSCMD.join(' ')} #{pid}`
@@ -620,7 +621,8 @@ class TestRubyOptions < Test::Unit::TestCase
pid = spawn(EnvUtil.rubybin, "test-script")
ps = nil
- stop = Process.clock_gettime(Process::CLOCK_MONOTONIC) + 30
+ now = Process.clock_gettime(Process::CLOCK_MONOTONIC)
+ stop = now + 30
begin
sleep 0.1
ps = `#{PSCMD.join(' ')} #{pid}`