diff --git a/composer.json b/composer.json index 7d9492fda716..fd1bd7651328 100644 --- a/composer.json +++ b/composer.json @@ -24,7 +24,8 @@ "phpunit/phpunit": "^9.1", "predis/predis": "^1.1", "rector/rector": "0.10.21", - "squizlabs/php_codesniffer": "^3.3" + "squizlabs/php_codesniffer": "^3.3", + "symplify/composer-json-manipulator": "^9.3" }, "suggest": { "ext-fileinfo": "Improves mime type detection for files" diff --git a/rector.php b/rector.php index d32d7210a636..7f4305fd2bdd 100644 --- a/rector.php +++ b/rector.php @@ -16,6 +16,7 @@ use Rector\Core\ValueObject\PhpVersion; use Rector\DeadCode\Rector\Concat\RemoveConcatAutocastRector; use Rector\DeadCode\Rector\Foreach_\RemoveUnusedForeachKeyRector; +use Rector\DeadCode\Rector\Property\RemoveUnusedPrivatePropertyRector; use Rector\DeadCode\Rector\Switch_\RemoveDuplicatedCaseInSwitchRector; use Rector\EarlyReturn\Rector\Foreach_\ChangeNestedForeachIfsToEarlyContinueRector; use Rector\EarlyReturn\Rector\If_\ChangeIfElseValueAssignToEarlyReturnRector; @@ -80,4 +81,5 @@ $services->set(RemoveConcatAutocastRector::class); $services->set(ChangeArrayPushToArrayAssignRector::class); $services->set(UnnecessaryTernaryExpressionRector::class); + $services->set(RemoveUnusedPrivatePropertyRector::class); }; diff --git a/tests/system/Helpers/DateHelperTest.php b/tests/system/Helpers/DateHelperTest.php index 68e7d99e097b..806d4e8a1fd9 100644 --- a/tests/system/Helpers/DateHelperTest.php +++ b/tests/system/Helpers/DateHelperTest.php @@ -6,12 +6,6 @@ final class DateHelperTest extends CIUnitTestCase { - - private $name; - private $value; - private $expire; - private $response; - protected function setUp(): void { parent::setUp();