Skip to main content

Branch protection

CI only protects your extension when a failing job can stop a merge. Set up branch protection rules or a ruleset in GitHub so that the tests must pass before a merge.

Require the jobs of every Drupal major you selected in the installer:

DrupalRequired jobs
10lint-d10, test-php-min-d10-stable, test-php-max-d10-stable
11lint-d11, test-php-min-d11-stable, test-php-max-d11-stable, test-php-min-d11-legacy, test-php-max-d11-canary
12lint-d12, test-php-min-d12-stable, test-php-max-d12-stable, test-php-min-d12-legacy, test-php-max-d12-canary

GitHub names each status check after its job, so a job you rename or shard needs the same change in your rules. Adding a Drupal major later adds its jobs, and those need adding here too.

A required check that never reports blocks every merge, so remove the checks of a Drupal major you stop testing.