Skip to content

Commit cf2c77e

Browse files
committed
Install Rector to help migrate toward PHPUnit 10+
1 parent 57b2d62 commit cf2c77e

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@
3636
"require-dev": {
3737
"facile-it/facile-coding-standard": "^1.2",
3838
"jangregor/phpstan-prophecy": "2.2.0",
39+
"phpspec/prophecy-phpunit": "^2.0",
3940
"phpstan/extension-installer": "^1.4",
4041
"phpstan/phpstan": "2.1.17",
4142
"phpstan/phpstan-phpunit": "2.0.6",
4243
"phpunit/phpunit": "^9.6.6",
43-
"phpspec/prophecy-phpunit": "^2.0",
44+
"rector/rector": "2.0.17",
4445
"symfony/phpunit-bridge": "^6.4 || ^7.0",
4546
"vimeo/psalm": "^4.6 || ^5.0"
4647
}

rector.php

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Rector\Config\RectorConfig;
6+
7+
return RectorConfig::configure()
8+
->withPaths([
9+
__DIR__ . '/src',
10+
__DIR__ . '/tests',
11+
])
12+
// uncomment to reach your current PHP version
13+
// ->withPhpSets()
14+
->withTypeCoverageLevel(0)
15+
->withDeadCodeLevel(0)
16+
->withCodeQualityLevel(0)
17+
->withSets([
18+
\Rector\PHPUnit\Set\PHPUnitSetList::PHPUNIT_100,
19+
])
20+
;

0 commit comments

Comments
 (0)