diff --git a/tests/Rules/NarrowPublicClassMethodParamTypeRule/Fixture/SkipDateTimeMix.php b/tests/Rules/NarrowPublicClassMethodParamTypeRule/Fixture/SkipDateTimeMix.php new file mode 100644 index 00000000..c64230a9 --- /dev/null +++ b/tests/Rules/NarrowPublicClassMethodParamTypeRule/Fixture/SkipDateTimeMix.php @@ -0,0 +1,23 @@ +markDate( + new \DateTimeImmutable('15:30') + ); + } +} diff --git a/tests/Rules/NarrowPublicClassMethodParamTypeRule/NarrowPublicClassMethodParamTypeRuleTest.php b/tests/Rules/NarrowPublicClassMethodParamTypeRule/NarrowPublicClassMethodParamTypeRuleTest.php index 88578e0c..fa6295bb 100644 --- a/tests/Rules/NarrowPublicClassMethodParamTypeRule/NarrowPublicClassMethodParamTypeRuleTest.php +++ b/tests/Rules/NarrowPublicClassMethodParamTypeRule/NarrowPublicClassMethodParamTypeRuleTest.php @@ -26,6 +26,7 @@ public function testRule(array $filePaths, array $expectedErrorsWithLines): void public static function provideData(): Iterator { + yield [[__DIR__ . '/Fixture/SkipDateTimeMix.php'], []]; yield [[__DIR__ . '/Fixture/SkipNonPublicClassMethod.php'], []]; // skip first class callables as anything can be passed there