Skip to content

Commit

Permalink
Merge pull request #9 from nucleos/tools
Browse files Browse the repository at this point in the history
Use composer scripts instead of make
  • Loading branch information
core23 committed Jan 20, 2020
2 parents e782699 + a7c49aa commit e64130a
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 30 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
php${{ matrix.php-version }}-php-cs-fixer-
- name: "Run friendsofphp/php-cs-fixer"
run: vendor/bin/php-cs-fixer fix --diff --diff-format=udiff --dry-run --verbose
run: composer cs-diff

static-code-analysis:
name: "Static Code Analysis"
Expand Down Expand Up @@ -96,7 +96,7 @@ jobs:
run: composer install --no-interaction --no-progress --no-suggest

- name: "Run phpstan/phpstan"
run: vendor/bin/phpstan analyse
run: composer phpstan

tests:
name: "Tests"
Expand Down Expand Up @@ -148,7 +148,7 @@ jobs:
run: composer update --no-interaction --no-progress --no-suggest

- name: "Run tests with phpunit/phpunit"
run: vendor/bin/phpunit
run: composer test

code-coverage:
name: "Code Coverage"
Expand Down Expand Up @@ -183,7 +183,7 @@ jobs:
run: composer install --no-interaction --no-progress --no-suggest

- name: "Collect code coverage with pcov and phpunit/phpunit"
run: vendor/bin/phpunit --coverage-clover=build/logs/clover.xml
run: composer coverage

- name: "Send code coverage report to Codecov.io"
env:
Expand Down Expand Up @@ -220,4 +220,4 @@ jobs:
run: composer install --no-interaction --no-progress --no-suggest

- name: "Run mutation tests with pcov and infection/infection"
run: vendor/bin/infection --ignore-msi-with-no-mutations --min-covered-msi=55 --min-msi=19
run: composer infection
24 changes: 0 additions & 24 deletions Makefile

This file was deleted.

13 changes: 12 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,17 @@
],
"post-update-cmd": [
"@composer bin all update --ansi"
]
],
"coverage": "vendor/bin/phpunit --colors=always --coverage-clover=build/logs/clover.xml",
"cs": "PHP_CS_FIXER_IGNORE_ENV=1 && vendor/bin/php-cs-fixer fix --verbose",
"cs-diff": "PHP_CS_FIXER_IGNORE_ENV=1 && vendor/bin/php-cs-fixer fix --verbose --diff --diff-format=udiff --dry-run",
"deps": "vendor/bin/composer-require-checker check --config-file composer-require.json composer.json",
"infection": "vendor/bin/infection --ignore-msi-with-no-mutations --min-covered-msi=55 --min-msi=19",
"lint": [
"find ./src \\( -name '*.xml' -or -name '*.xml.dist' -or -name '*.xlf' \\) -type f -exec xmllint --encode UTF-8 --output '{}' --format '{}' \\;",
"find ./src \\( -name '*.yml' -or -name '*.yaml' \\) -not -path '*/vendor/*' | xargs yaml-lint"
],
"phpstan": "vendor/bin/phpstan analyse",
"test": "vendor/bin/phpunit --colors=always --coverage-clover build/logs/clover.xml"
}
}

0 comments on commit e64130a

Please sign in to comment.