Skip to content

Commit

Permalink
Fix: Issues reported via static analysis
Browse files Browse the repository at this point in the history
  • Loading branch information
localheinz committed Dec 23, 2019
1 parent 79891bd commit b825749
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions test/Unit/FactoryTest.php
Expand Up @@ -95,7 +95,6 @@ public function testFromRuleSetCreatesConfig(int $targetPhpVersion): void

$config = Config\Factory::fromRuleSet($ruleSet->reveal());

self::assertInstanceOf(ConfigInterface::class, $config);
self::assertTrue($config->getUsingCache());
self::assertTrue($config->getRiskyAllowed());
self::assertSame($rules, $config->getRules());
Expand Down Expand Up @@ -155,7 +154,6 @@ public function testFromRuleSetCreatesConfigWithOverrideRules(): void
$overrideRules
);

self::assertInstanceOf(ConfigInterface::class, $config);
self::assertTrue($config->getUsingCache());
self::assertTrue($config->getRiskyAllowed());
self::assertSame(\array_merge($rules, $overrideRules), $config->getRules());
Expand Down
4 changes: 2 additions & 2 deletions test/Unit/RuleSet/AbstractRuleSetTestCase.php
Expand Up @@ -227,7 +227,7 @@ private function builtInFixers(): array
$fixerFactory = FixerFactory::create();
$fixerFactory->registerBuiltInFixers();

$builtInFixers = \array_map(static function (Fixer\FixerInterface $fixer) {
$builtInFixers = \array_map(static function (Fixer\FixerInterface $fixer): string {
return $fixer->getName();
}, $fixerFactory->getFixers());
}
Expand All @@ -242,7 +242,7 @@ private function configuredFixers(): array
*
* @see https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/2361
*/
$rules = \array_map(static function () {
$rules = \array_map(static function (): bool {
return true;
}, self::createRuleSet()->rules());

Expand Down

0 comments on commit b825749

Please sign in to comment.