Skip to content

Commit

Permalink
Merge pull request #90 from driehle/upgrade-phpstan
Browse files Browse the repository at this point in the history
Upgraded PHPStan from 1.12 to 2.0
  • Loading branch information
driehle authored Nov 28, 2024
2 parents 24c3ac8 + a14234c commit da0dbd1
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,21 @@ on:
branches:
- "*.x"
paths:
- ".github/workflows/phpstan.yml"
- ".github/workflows/static-analysis.yml"
- "composer.*"
- "src/**"
- "phpstan*"
- "psalm*"
- "tests/**"
push:
branches:
- "*.x"
paths:
- ".github/workflows/phpstan.yml"
- ".github/workflows/static-analysis.yml"
- "composer.*"
- "src/**"
- "phpstan*"
- "psalm*"
- "tests/**"

jobs:
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
"require-dev": {
"doctrine/coding-standard": "^12.0.0",
"phpdocumentor/guides-cli": "^1.5.0",
"phpstan/phpstan": "^1.12.11",
"phpstan/phpstan": "^2.0.2",
"phpunit/phpunit": "^10.5.38",
"vimeo/psalm": "^5.15.0"
"vimeo/psalm": "^5.26.1"
},
"autoload": {
"psr-4": {
Expand Down
6 changes: 5 additions & 1 deletion phpstan.neon
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
parameters:
level: 6
checkGenericClassInNonGenericObjectType: false
treatPhpDocTypesAsCertain: false
paths:
- src
- tests
ignoreErrors:
-
identifier: missingType.generics
-
identifier: method.alreadyNarrowedType
-
message: '#expects .*Collection<\(int\|string\), object>, .*ArrayCollection<int, Doctrine.*Entity> given#'
path: tests/DoctrineObjectTest.php
Expand Down

0 comments on commit da0dbd1

Please sign in to comment.