Skip to content

Commit

Permalink
[BUGFIX] Avoid unsetting almost all PHP-CS-Fixes rules
Browse files Browse the repository at this point in the history
Followup to #1533
  • Loading branch information
oliverklee authored and DanielSiepmann committed Jan 3, 2025
1 parent 6c264c6 commit 22c89bb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
use TYPO3\CodingStandards\CsFixerConfig;

$config = CsFixerConfig::create();

// This is required as long as we are on PHPUnit 9.x. It can be removed after the switch to PHPUnit 10.x.
// @see https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8337
$config->setRules(
[
'php_unit_test_case_static_method_calls' => ['call_type' => 'self', 'methods' => ['createStub' => 'this']],
]
);
$rules = $config->getRules();
$rules['php_unit_test_case_static_method_calls'] = ['call_type' => 'self', 'methods' => ['createStub' => 'this']];
$config->setRules($rules);

// @TODO 4.0 no need to call this manually
$config->setParallelConfig(ParallelConfigFactory::detect());

$config->getFinder()->in('Classes')->in('Configuration')->in('Tests');
return $config;

0 comments on commit 22c89bb

Please sign in to comment.