Skip to content

Commit

Permalink
[TASK] Upgrade to PHPStan 2.x and Rector 2.x (#777)
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverklee authored Dec 12, 2024
1 parent 36de90d commit 72899b5
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
5 changes: 5 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ updates:
interval: "daily"
allow:
- dependency-type: "development"
ignore:
- dependency-name: "phpstan/*"
- dependency-name: "phpunit/phpunit"
versions: [ ">= 9.0.0" ]
- dependency-name: "rector/rector"
versioning-strategy: "increase"
commit-message:
prefix: "[Dependabot] "
Expand Down
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@
"require-dev": {
"php-parallel-lint/php-parallel-lint": "1.4.0",
"phpstan/extension-installer": "1.4.3",
"phpstan/phpstan": "1.12.9",
"phpstan/phpstan-phpunit": "1.4.0",
"phpstan/phpstan": "1.12.12 || 2.0.3",
"phpstan/phpstan-phpunit": "1.4.1 || 2.0.1",
"phpunit/phpunit": "8.5.40",
"rector/rector": "1.2.10"
"rector/rector": "1.2.10 || 2.0.0"
},
"suggest": {
"ext-mbstring": "for parsing UTF-8 CSS"
Expand Down
12 changes: 10 additions & 2 deletions config/phpstan-baseline.neon
Original file line number Diff line number Diff line change
@@ -1,12 +1,20 @@
parameters:
ignoreErrors:
-
message: "#^Call to an undefined method Sabberworm\\\\CSS\\\\OutputFormat\\:\\:setIndentation\\(\\)\\.$#"
message: '#^Call to an undefined method Sabberworm\\CSS\\OutputFormat\:\:setIndentation\(\)\.$#'
identifier: method.notFound
count: 2
path: ../src/OutputFormat.php

-
message: "#^Class Sabberworm\\\\CSS\\\\Value\\\\Size constructor invoked with 5 parameters, 1\\-4 required\\.$#"
message: '#^Class Sabberworm\\CSS\\Value\\Size constructor invoked with 5 parameters, 1\-4 required\.$#'
identifier: arguments.count
count: 2
path: ../src/RuleSet/DeclarationBlock.php

-
message: '#^@covers value \\Sabberworm\\CSS\\Value\\Value\:\:parseValue\(\) references an invalid method\.$#'
identifier: phpunit.coversMethod
count: 2
path: ../tests/ParserTest.php

0 comments on commit 72899b5

Please sign in to comment.