Skip to content

Instantly share code, notes, and snippets.

@kerasai
Last active January 29, 2025 15:46
Show Gist options
  • Save kerasai/0f7dcb5842ffb7053f238abdaa90358d to your computer and use it in GitHub Desktop.
Save kerasai/0f7dcb5842ffb7053f238abdaa90358d to your computer and use it in GitHub Desktop.
DrupalCI Tests

Set up tests

Kernel tests

Requries core dev tools:

composer require drupal/core-dev

Run phpunit w/no configuration and use core bootstrap file. Note, this needs full path to bootstrap file.

vendor/bin/phpunit --no-configuration --bootstrap /app/web/core/tests/bootstrap.php web/modules/custom/

Running on Drupal.org's CI

To run on drupal.org:

  • Add the .gitlab-ci.yml file
  • Ensure the project has a composer.json file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment