From d4f77abcd44672075342e2b8647f583b734671c4 Mon Sep 17 00:00:00 2001 From: "John Paul E. Balandan, CPA" Date: Sun, 5 Nov 2023 18:41:18 +0800 Subject: [PATCH] Fix phpstan baselined errors --- phpstan-baseline.php | 3 --- tests/Type/DynamicFunctionReturnTypeExtensionTest.php | 3 +++ tests/Type/DynamicMethodReturnTypeExtensionTest.php | 3 +++ 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/phpstan-baseline.php b/phpstan-baseline.php index a54eda5..ce8efea 100644 --- a/phpstan-baseline.php +++ b/phpstan-baseline.php @@ -1,8 +1,5 @@ '#^Method CodeIgniter\\\\PHPStan\\\\Tests\\\\Type\\\\\\S+Test\\:\\:\\S+\\(\\) return type has no value type specified in iterable type iterable\\.$#', -]; return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/Type/DynamicFunctionReturnTypeExtensionTest.php b/tests/Type/DynamicFunctionReturnTypeExtensionTest.php index 87becbc..86ba30b 100644 --- a/tests/Type/DynamicFunctionReturnTypeExtensionTest.php +++ b/tests/Type/DynamicFunctionReturnTypeExtensionTest.php @@ -32,6 +32,9 @@ public function testFileAsserts(string $assertType, string $file, mixed ...$args $this->assertFileAsserts($assertType, $file, ...$args); } + /** + * @return iterable + */ public static function provideFileAssertsCases(): iterable { yield from self::gatherAssertTypes(__DIR__ . '/../Fixtures/Type/config.php'); diff --git a/tests/Type/DynamicMethodReturnTypeExtensionTest.php b/tests/Type/DynamicMethodReturnTypeExtensionTest.php index c0119ee..62d4e91 100644 --- a/tests/Type/DynamicMethodReturnTypeExtensionTest.php +++ b/tests/Type/DynamicMethodReturnTypeExtensionTest.php @@ -32,6 +32,9 @@ public function testFileAsserts(string $assertType, string $file, mixed ...$args $this->assertFileAsserts($assertType, $file, ...$args); } + /** + * @return iterable + */ public static function provideFileAssertsCases(): iterable { yield from self::gatherAssertTypes(__DIR__ . '/../Fixtures/Type/model-find.php');