|
| 1 | +<?php |
| 2 | + |
| 3 | +declare(strict_types=1); |
| 4 | + |
| 5 | +use Rector\Config\RectorConfig; |
| 6 | + |
| 7 | +return RectorConfig::configure() |
| 8 | + ->withPhpSets(php84: true) |
| 9 | + ->withAttributesSets(phpunit: true) |
| 10 | + ->withRules([ |
| 11 | + Rector\CodeQuality\Rector\Ternary\ArrayKeyExistsTernaryThenValueToCoalescingRector::class, |
| 12 | + Rector\CodeQuality\Rector\NullsafeMethodCall\CleanupUnneededNullsafeOperatorRector::class, |
| 13 | + Rector\CodeQuality\Rector\ClassMethod\InlineArrayReturnAssignRector::class, |
| 14 | + Rector\CodeQuality\Rector\Ternary\UnnecessaryTernaryExpressionRector::class, |
| 15 | + Rector\DeadCode\Rector\Foreach_\RemoveUnusedForeachKeyRector::class, |
| 16 | + Rector\TypeDeclaration\Rector\ClassMethod\ReturnTypeFromStrictFluentReturnRector::class, |
| 17 | + Rector\Php80\Rector\Class_\StringableForToStringRector::class, |
| 18 | + Rector\CodingStyle\Rector\ArrowFunction\StaticArrowFunctionRector::class, |
| 19 | + Rector\CodingStyle\Rector\Closure\StaticClosureRector::class, |
| 20 | + Rector\DeadCode\Rector\Node\RemoveNonExistingVarAnnotationRector::class, |
| 21 | + Rector\DeadCode\Rector\ClassMethod\RemoveUnusedPrivateMethodParameterRector::class, |
| 22 | + Rector\TypeDeclaration\Rector\ClassMethod\BoolReturnTypeFromBooleanStrictReturnsRector::class, |
| 23 | + Rector\TypeDeclaration\Rector\ClassMethod\ReturnTypeFromReturnNewRector::class, |
| 24 | + Rector\TypeDeclaration\Rector\ClassMethod\ParamTypeByMethodCallTypeRector::class, |
| 25 | + Rector\TypeDeclaration\Rector\ClassMethod\NumericReturnTypeFromStrictScalarReturnsRector::class, |
| 26 | + Rector\TypeDeclaration\Rector\ClassMethod\AddMethodCallBasedStrictParamTypeRector::class, |
| 27 | + Rector\CodeQuality\Rector\If_\ExplicitBoolCompareRector::class, |
| 28 | + Rector\CodeQuality\Rector\Foreach_\ForeachItemsAssignToEmptyArrayToAssignRector::class, |
| 29 | + Rector\CodeQuality\Rector\Foreach_\ForeachToInArrayRector::class, |
| 30 | + Rector\CodeQuality\Rector\BooleanAnd\RemoveUselessIsObjectCheckRector::class, |
| 31 | + ]) |
| 32 | + ->withPaths([ |
| 33 | + __DIR__ . '/src', |
| 34 | + __DIR__ . '/tests', |
| 35 | + ]) |
| 36 | + ->withTypeCoverageLevel(0); |
0 commit comments