From 7339bf3e42d3c426f069d51e4fbc3edc3402584f Mon Sep 17 00:00:00 2001 From: Camille Simiand <camille.simiand@tetras-libre.fr> Date: Tue, 23 Nov 2021 17:24:39 +0100 Subject: [PATCH] Add composer scripts - php-cs-fixer - phpstan - unit tests (phpunit) For now, scripts are running to check only on src/ directory To run the CI script: `composer run ci` --- composer.json | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/composer.json b/composer.json index c63fa1e..2c2dbb9 100644 --- a/composer.json +++ b/composer.json @@ -92,7 +92,15 @@ ], "post-update-cmd": [ "@auto-scripts" - ] + ], + "ci": [ + "@php-cs-fixer", + "@phpstan", + "@unit-tests" + ], + "php-cs-fixer": "tools/php-cs-fixer/vendor/bin/php-cs-fixer fix src/", + "phpstan": "vendor/bin/phpstan analyse src/", + "unit-tests": "php ./vendor/bin/phpunit" }, "conflict": { "symfony/symfony": "*" -- GitLab