feat(github-actions): run tests first

The tests are the most valuable part of the CI pipeline, so these should
be run first.

If a PHPCS or PHPStan error occurs but the tests pass, we know the
functionality works and the error can be addressed.

If a test fails, the CI pipeline will fail sooner.

In the future, the tasks could be split into separate jobs though it
would need to be done in a way that doesn't add a lot of repetition.

Refs: OD-41
This commit is contained in:
Oliver Davies 2023-08-19 08:40:15 +01:00
parent c68bca3d56
commit 17142d868f

View file

@ -40,6 +40,8 @@ jobs:
just composer install --quiet --no-progress
just test --testdox --colors=always
{% if "phpcs" in php|keys -%}
just _run php phpcs
{%- endif %}
@ -47,5 +49,3 @@ jobs:
{% if "phpstan" in php|keys -%}
just _run php phpstan analyze --no-progress --memory-limit=512M
{%- endif %}
just test --testdox --colors=always