File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed
railties/lib/rails/generators/rails/app/templates/github Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change
1
+ * Use logical core count instead of physical core count to determine the
2
+ default number of workers when parallelizing tests.
3
+
4
+ * Jonathan Hefner*
5
+
1
6
* Fix ` Time.now/DateTime.now/Date.today' to return results in a system timezone after ` #travel_to'.
2
7
3
8
There is a bug in the current implementation of #travel_to:
Original file line number Diff line number Diff line change @@ -78,7 +78,7 @@ def test_order
78
78
# number of tests to run is above the +threshold+ param. The default value is
79
79
# 50, and it's configurable via +config.active_support.test_parallelization_threshold+.
80
80
def parallelize ( workers : :number_of_processors , with : :processes , threshold : ActiveSupport . test_parallelization_threshold )
81
- workers = Concurrent . physical_processor_count if workers == :number_of_processors
81
+ workers = Concurrent . processor_count if workers == :number_of_processors
82
82
workers = ENV [ "PARALLEL_WORKERS" ] . to_i if ENV [ "PARALLEL_WORKERS" ]
83
83
84
84
Minitest . parallel_executor = ActiveSupport ::Testing ::ParallelizeExecutor . new ( size : workers , with : with , threshold : threshold )
Original file line number Diff line number Diff line change @@ -110,9 +110,6 @@ jobs:
110
110
ruby-version: .ruby-version
111
111
bundler-cache: true
112
112
113
- - name: Configure parallelization
114
- run: echo "PARALLEL_WORKERS=$(nproc)" >> $GITHUB_ENV
115
-
116
113
- name: Run tests
117
114
env:
118
115
RAILS_ENV: test
You can’t perform that action at this time.
0 commit comments