Problem/Motivation

In #3386076: GitLab CI integration for core we added two new arguments to the run-tests.sh to allow paralell runs, but the simpletest_script_help() was not updated to describe these new parameters.

diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh
@@ -404,6 +404,8 @@ function simpletest_script_parse_args() {
     'xml' => '',
     'non-html' => FALSE,
+    'ci-parallel-node-index' => 1,
+    'ci-parallel-node-total' => 1,
 
@@ -1024,6 +1026,12 @@ function simpletest_script_get_test_list() {
+  if ((int) $args['ci-parallel-node-total'] > 1) {
+    $tests_per_job = ceil(count($test_list) / $args['ci-parallel-node-total']);
+    $test_list = array_slice($test_list, ($args['ci-parallel-node-index'] - 1) * $tests_per_job, $tests_per_job);
+  }

I think we should add at least a brief description here.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Issue fork drupal-3387959

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

poker10 created an issue. See original summary.

poker10’s picture

Added an MR with this change. I have added only a brief description to the both arguments (taken from https://docs.gitlab.com/ee/ci/variables/predefined_variables.html), but can be tweaked if needed.

poker10’s picture

Status: Active » Needs review
smustgrave’s picture

Status: Needs review » Reviewed & tested by the community

Document changes read well and short and sweet to what the parameters do. +1

xjm’s picture

Priority: Minor » Normal

  • xjm committed 5e2dcabf on 11.x
    Issue #3387959 by poker10: Document new arguments in run-tests.sh
    

  • xjm committed 51ea0f69 on 10.2.x
    Issue #3387959 by poker10: Document new arguments in run-tests.sh
    
    (...
xjm’s picture

Version: 11.x-dev » 10.1.x-dev
Status: Reviewed & tested by the community » Fixed

Committed to 11.x, 10.2.x, and 10.1.x as a developer documentation bugfix. Thanks!

  • xjm committed 126c7621 on 10.1.x
    Issue #3387959 by poker10: Document new arguments in run-tests.sh
    
    (...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

xjm’s picture

Amending attribution.