Skip to content

Commit

Permalink
Merge pull request #907 from ergebnis/feature/rector-rules
Browse files Browse the repository at this point in the history
Enhancement: Require and use `ergebnis/rector-rules`
  • Loading branch information
localheinz committed Sep 30, 2023
2 parents 87b3772 + 3dc40bb commit 4984242
Show file tree
Hide file tree
Showing 12 changed files with 224 additions and 341 deletions.
1 change: 0 additions & 1 deletion .php-cs-fixer.php
Expand Up @@ -35,7 +35,6 @@
'.build/',
'.github/',
'.note/',
'test/Fixture/',
])
->ignoreDotFiles(false)
->in(__DIR__);
Expand Down
1 change: 1 addition & 0 deletions composer.json
Expand Up @@ -28,6 +28,7 @@
"ergebnis/data-provider": "^3.0.0",
"ergebnis/license": "^2.2.0",
"ergebnis/phpunit-slow-test-detector": "^2.3.0",
"ergebnis/rector-rules": "~0.1.0",
"fakerphp/faker": "^1.23.0",
"phpunit/phpunit": "^10.3.5",
"psalm/plugin-phpunit": "~0.18.4",
Expand Down
226 changes: 219 additions & 7 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions psalm-baseline.xml
Expand Up @@ -104,11 +104,6 @@
<code>provideValueGreaterThanNinetyNine</code>
</PossiblyUnusedMethod>
</file>
<file src="test/Unit/Rector/SortAssociativeArrayByKey/SortAssociativeArrayByKeyTest.php">
<PossiblyUnusedMethod>
<code>provideData</code>
</PossiblyUnusedMethod>
</file>
<file src="test/Unit/RuleSet/AbstractRuleSetTestCase.php">
<InternalClass>
<code>new FixerFactory()</code>
Expand Down
4 changes: 1 addition & 3 deletions psalm.xml
Expand Up @@ -18,9 +18,7 @@

<projectFiles>
<directory name="src/" />
<directory name="test/EndToEnd/" />
<directory name="test/Unit/" />
<directory name="test/Util/" />
<directory name="test/" />
<file name="rector.php" />
<ignoreFiles>
<directory name="vendor/" />
Expand Down
8 changes: 3 additions & 5 deletions rector.php
Expand Up @@ -11,7 +11,7 @@
* @see https://github.com/ergebnis/php-cs-fixer-config
*/

use Ergebnis\PhpCsFixer;
use Ergebnis\Rector\Rules;
use Rector\Config;
use Rector\Core;
use Rector\Php81;
Expand All @@ -24,16 +24,14 @@

$rectorConfig->paths([
__DIR__ . '/src/',
__DIR__ . '/test/EndToEnd/',
__DIR__ . '/test/Unit/',
__DIR__ . '/test/Util/',
__DIR__ . '/test/',
]);

$rectorConfig->phpVersion(Core\ValueObject\PhpVersion::PHP_81);

$rectorConfig->rules([
Php81\Rector\Property\ReadOnlyPropertyRector::class,
PhpCsFixer\Config\Test\Rector\SortAssociativeArrayByKey::class,
Rules\Arrays\SortAssociativeArrayByKeyRector::class,
]);

$rectorConfig->sets([
Expand Down
47 changes: 0 additions & 47 deletions test/Fixture/Rector/SortAssociativeArrayByKey/class.php.inc

This file was deleted.

0 comments on commit 4984242

Please sign in to comment.