mirror of
https://github.com/pestphp/pest.git
synced 2026-07-21 09:00:02 +02:00
38 lines
1.4 KiB
PHP
38 lines
1.4 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
use Rector\CodingStyle\Rector\ArrowFunction\ArrowFunctionDelegatingCallToFirstClassCallableRector;
|
|
use Rector\Config\RectorConfig;
|
|
use Rector\DeadCode\Rector\ClassMethod\RemoveDuplicatedReturnSelfDocblockRector;
|
|
use Rector\DeadCode\Rector\ClassMethod\RemoveParentDelegatingConstructorRector;
|
|
use Rector\DeadCode\Rector\ClassMethod\RemoveReturnTagIncompatibleWithNativeTypeRector;
|
|
use Rector\DeadCode\Rector\ClassMethod\RemoveUselessUnionReturnDocblockRector;
|
|
use Rector\TypeDeclaration\Rector\ClassMethod\NarrowObjectReturnTypeRector;
|
|
use Rector\TypeDeclaration\Rector\ClassMethod\ReturnNeverTypeRector;
|
|
|
|
return RectorConfig::configure()
|
|
->withPaths([
|
|
__DIR__.'/src',
|
|
])
|
|
->withSkip([
|
|
__DIR__.'/src/Plugins/Parallel/Paratest/WrapperRunner.php',
|
|
ReturnNeverTypeRector::class,
|
|
ArrowFunctionDelegatingCallToFirstClassCallableRector::class,
|
|
NarrowObjectReturnTypeRector::class,
|
|
RemoveParentDelegatingConstructorRector::class,
|
|
RemoveDuplicatedReturnSelfDocblockRector::class,
|
|
RemoveUselessUnionReturnDocblockRector::class,
|
|
RemoveReturnTagIncompatibleWithNativeTypeRector::class => [
|
|
__DIR__.'/src/Expectations/HigherOrderExpectation.php',
|
|
],
|
|
])
|
|
->withPreparedSets(
|
|
deadCode: true,
|
|
codeQuality: true,
|
|
typeDeclarations: true,
|
|
privatization: true,
|
|
earlyReturn: true,
|
|
)
|
|
->withPhpSets();
|