Skip to content

Commit f6c7d9d

Browse files
committed
Add PHPStan for our lovely new code.
1 parent 294da8d commit f6c7d9d

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,5 @@ script:
4848
- "git diff --exit-code"
4949
# Execute stubs
5050
- "php -f wordpress-stubs.php"
51+
# Analyse our code
52+
- "vendor/bin/phpstan"

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"php": "~7.3 || ~8.0",
1616
"phpdocumentor/reflection-docblock": "^5.3",
1717
"php-stubs/generator": "^0.8.0",
18+
"phpstan/phpstan": "^1.2",
1819
"nikic/php-parser": "< 4.12.0"
1920
},
2021
"suggest": {

phpstan.neon

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
parameters:
2+
level: 8
3+
paths:
4+
- visitor.php

0 commit comments

Comments
 (0)