Skip to content

Commit b3aacdc

Browse files
committed
Used already defined method parallelized? and fixed semantics of the test name.
- Related to rails#42761 - Used `parallelized?` method instead of calling a method `should_parallelize?` to figure out if parallezation is enabled. - Fixed semantics of the test name corresponding to the change - Updated test name as per the code review suggestion.
1 parent c183397 commit b3aacdc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

activesupport/lib/active_support/testing/parallelize_executor.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def show_execution_info
6161
end
6262

6363
def execution_info
64-
if should_parallelize?
64+
if parallelized?
6565
"Running #{tests_count} tests in parallel using #{parallel_executor.size} #{parallelize_with}"
6666
else
6767
"Running #{tests_count} tests in a single process (parallelization threshold is #{ActiveSupport.test_parallelization_minimum_number_of_tests})"

railties/test/application/test_runner_test.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -571,7 +571,7 @@ def test_run_in_parallel_with_processes
571571
assert_no_match "create_table(:users)", output
572572
end
573573

574-
def test_avoid_paralleling_when_number_of_tests_if_below_threshold
574+
def test_avoid_parallelizing_when_number_of_tests_is_below_threshold
575575
exercise_parallelization_regardless_of_machine_core_count(with: :processes, threshold: 100)
576576

577577
file_name = create_parallel_processes_test_file

0 commit comments

Comments
 (0)