Skip to content

Commit ccb7b04

Browse files
committed
Fix SA error
1 parent 72dc9e0 commit ccb7b04

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/Rules/PHPUnit/DataProviderDataRuleTest.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace PHPStan\Rules\PHPUnit;
44

5+
use PhpParser\Node;
56
use PHPStan\Testing\CompositeRule;
67
use PHPStan\Rules\Methods\CallMethodsRule;
78
use PHPStan\Rules\PHPUnit\DataProviderDataRule;
@@ -21,7 +22,8 @@ protected function getRule(): Rule
2122
{
2223
$reflectionProvider = $this->createReflectionProvider();
2324

24-
return new CompositeRule([
25+
/** @var list<Rule<Node>> $rules */
26+
$rules = [
2527
new DataProviderDataRule(
2628
new TestMethodsHelper(
2729
self::getContainer()->getByType(FileTypeMapper::class),
@@ -36,7 +38,9 @@ protected function getRule(): Rule
3638

3739
),
3840
self::getContainer()->getByType(CallMethodsRule::class) /** @phpstan-ignore phpstanApi.classConstant */
39-
]);
41+
];
42+
43+
return new CompositeRule($rules);
4044
}
4145

4246
public function testRule(): void

0 commit comments

Comments
 (0)