feat(justfile): add test-watch recipe

Automatically re-run tests when files change using nodemon.
This commit is contained in:
Oliver Davies 2023-05-11 20:50:44 +01:00
parent 3841a223f4
commit 590cb8ffc0

View file

@ -24,6 +24,9 @@ test *args:
{% else %}
{{ "just _run php phpunit --colors=always {{ args }}" | raw }}
{% endif %}
test-watch *args:
nodemon --ext "*" --watch "." --exec "just test {{ args }} || exit 1" --ignore */sites/simpletest
{% endif %}
{% if "drupal-project" is same as type %}
@ -96,7 +99,7 @@ test-commit:
{% endif %}
_exec +args:
{{ "docker compose exec {{ args }}" | raw }}
{{ "docker compose exec -T {{ args }}" | raw }}
_run service command *args:
docker compose run \