Skip to content

Commit eb0dc44

Browse files
committed
Rewrite in backward compatibility compliant way
1 parent d6df6a0 commit eb0dc44

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

tests/Type/WebMozartAssert/ImpossibleCheckTypeMethodCallRuleTest.php

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,7 @@ class ImpossibleCheckTypeMethodCallRuleTest extends \PHPStan\Testing\RuleTestCas
1414

1515
protected function getRule(): Rule
1616
{
17-
return new ImpossibleCheckTypeStaticMethodCallRule(new ImpossibleCheckTypeHelper($this->createBroker(), $this->getTypeSpecifier(), [], true), true, true);
18-
}
19-
20-
/**
21-
* @return \PHPStan\Type\StaticMethodTypeSpecifyingExtension[]
22-
*/
23-
protected function getStaticMethodTypeSpecifyingExtensions(): array
24-
{
25-
return [
26-
new AssertTypeSpecifyingExtension(),
27-
];
17+
return new ImpossibleCheckTypeStaticMethodCallRule(self::getContainer()->getByType(ImpossibleCheckTypeHelper::class), true, true);
2818
}
2919

3020
public function testExtension(): void
@@ -37,4 +27,11 @@ public function testExtension(): void
3727
]);
3828
}
3929

30+
public static function getAdditionalConfigFiles(): array
31+
{
32+
return [
33+
__DIR__ . '/../../../extension.neon',
34+
];
35+
}
36+
4037
}

0 commit comments

Comments
 (0)