aboutsummaryrefslogtreecommitdiffstats
path: root/test/lib
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-02-05 16:07:30 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-02-05 16:07:30 +0000
commitd995990a4c5432d8e49b6b2e79bbf6a29f8f8d6b (patch)
treea02fc215cc89734c6e6bda92550b55b04acde54e /test/lib
parentb80f60fffb11e2516ac1c69d8e223eafa74120a9 (diff)
downloadruby-d995990a4c5432d8e49b6b2e79bbf6a29f8f8d6b.tar.gz
@job_tokens is defined iff @jobserver is true
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57541 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/lib')
-rw-r--r--test/lib/test/unit.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/lib/test/unit.rb b/test/lib/test/unit.rb
index 9173e5414c..f3aff4ee8c 100644
--- a/test/lib/test/unit.rb
+++ b/test/lib/test/unit.rb
@@ -458,7 +458,7 @@ module Test
(deal(io, type, result, rep).nil? and
!@workers.any? {|x| [:running, :prepare].include? x.status})
end
- if @job_tokens and !@tasks.empty? and !@workers.any? {|x| x.status == :ready}
+ if @jobserver and @job_tokens and !@tasks.empty? and !@workers.any? {|x| x.status == :ready}
t = @jobserver[0].read_nonblock([@tasks.size, @options[:parallel]].min, exception: false)
if String === t
@job_tokens << t