Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add phpstan #10

Merged
merged 2 commits into from
Jun 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@
/.gitignore export-ignore
/.php-cs-fixer.dist.php export-ignore
/.github export-ignore
/phpstan.neon export-ignore
/phpstan-baseline.neon export-ignore
2 changes: 2 additions & 0 deletions .github/workflows/code_checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,5 @@ jobs:
- run: composer install -a --no-interaction --no-progress --prefer-dist

- run: composer test-cs-fixer

- run: composer phpstan:check
8 changes: 6 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@
"phpmd/phpmd": "^2.6",
"phpunit/phpunit": "^9.5",
"squizlabs/php_codesniffer": "^2.9",
"symfony/phpunit-bridge": "^6.1"
"symfony/phpunit-bridge": "^6.1",
"phpstan/phpstan": "^1.7",
"phpstan/phpstan-phpunit": "^1.1",
"phpstan/phpstan-strict-rules": "^1.2"
},
"minimum-stability": "stable",
"autoload": {
Expand Down Expand Up @@ -58,7 +61,8 @@
"test-cs-fixer": "./vendor/bin/php-cs-fixer fix --diff --dry-run -v",
"test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming",
"test-unit": "./vendor/phpunit/phpunit/phpunit --coverage-text",
"test-unit-phpdbg": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text"
"test-unit-phpdbg": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text",
"phpstan:check": "@php vendor/bin/phpstan analyse -c phpstan.neon src tests"
},
"funding": [
{
Expand Down
Loading