class method self.parallel_worker_id

Ruby on Rails edge

Since v8.1.3.1

Available in: v8.1.3.1 edge

Signature

self.parallel_worker_id()

Returns the current parallel worker ID if tests are running in parallel, nil otherwise.

ActiveSupport::TestCase.parallel_worker_id # => 2
Source
# File activesupport/lib/active_support/test_case.rb, line 34
      def parallel_worker_id
        @@parallel_worker_id
      end

Defined in activesupport/lib/active_support/test_case.rb line 34 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveSupport::TestCase

Type at least 2 characters to search.

Use the arrow keys to navigate results, Enter to open one, Escape to close.

Keyboard shortcuts

/
Focus search
⌘K / Ctrl-K
Command palette
?
This help
Esc
Close