From ea16d745eb966d868fb6160c2aeaa0d05bcf369b Mon Sep 17 00:00:00 2001 From: Alexandre D'Eschambeault Date: Tue, 26 Mar 2024 11:19:05 -0400 Subject: [PATCH] test: provider should be static in phpunit v10 --- tests/Feature/BladeTest.php | 2 +- tests/Unit/Strategy/CallbackTest.php | 2 +- tests/Unit/Strategy/ConfigTest.php | 2 +- tests/Unit/Strategy/DateTest.php | 2 +- tests/Unit/Strategy/EnvironmentTest.php | 2 +- tests/Unit/Strategy/HostnameTest.php | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/Feature/BladeTest.php b/tests/Feature/BladeTest.php index 07a4889..21433a8 100644 --- a/tests/Feature/BladeTest.php +++ b/tests/Feature/BladeTest.php @@ -30,7 +30,7 @@ public function testDirective(string $directive, bool $state): void /** * @return \Generator */ - public function provideTestDirective(): Generator + public static function provideTestDirective(): Generator { yield ['launch', true]; yield ['launch', false]; diff --git a/tests/Unit/Strategy/CallbackTest.php b/tests/Unit/Strategy/CallbackTest.php index 502ff9b..cc5da84 100644 --- a/tests/Unit/Strategy/CallbackTest.php +++ b/tests/Unit/Strategy/CallbackTest.php @@ -26,7 +26,7 @@ public function testLaunch($expected): void /** * @return \Generator */ - public function provideTestLaunch(): Generator + public static function provideTestLaunch(): Generator { yield [true]; yield [false]; diff --git a/tests/Unit/Strategy/ConfigTest.php b/tests/Unit/Strategy/ConfigTest.php index 3426bb4..e09e16e 100644 --- a/tests/Unit/Strategy/ConfigTest.php +++ b/tests/Unit/Strategy/ConfigTest.php @@ -44,7 +44,7 @@ public function testLaunch(bool $expected): void /** * @return array */ - public function provideTestLaunch(): array + public static function provideTestLaunch(): array { return [ [true], diff --git a/tests/Unit/Strategy/DateTest.php b/tests/Unit/Strategy/DateTest.php index a2d8ce7..e7ecd1d 100644 --- a/tests/Unit/Strategy/DateTest.php +++ b/tests/Unit/Strategy/DateTest.php @@ -49,7 +49,7 @@ public function testLaunch($date, $operator, $expected): void /** * @return \Generator */ - public function provideTestLaunch(): Generator + public static function provideTestLaunch(): Generator { yield ['2019-12-31', '<', true]; yield ['2020-01-01', '<', false]; diff --git a/tests/Unit/Strategy/EnvironmentTest.php b/tests/Unit/Strategy/EnvironmentTest.php index 24ca496..e9a1124 100644 --- a/tests/Unit/Strategy/EnvironmentTest.php +++ b/tests/Unit/Strategy/EnvironmentTest.php @@ -46,7 +46,7 @@ public function testLaunch($environments, string $actualEnvironment, bool $expec /** * @return \Generator */ - public function provideTestLaunch(): Generator + public static function provideTestLaunch(): Generator { yield ['local', 'local', true]; yield ['local', 'production', false]; diff --git a/tests/Unit/Strategy/HostnameTest.php b/tests/Unit/Strategy/HostnameTest.php index 301be41..ad5f87f 100644 --- a/tests/Unit/Strategy/HostnameTest.php +++ b/tests/Unit/Strategy/HostnameTest.php @@ -33,7 +33,7 @@ public function testLaunch($hosts, string $actualHost, bool $expectedLaunch): vo /** * @return \Generator */ - public function provideTestLaunch(): Generator + public static function provideTestLaunch(): Generator { yield ['localhost', 'localhost', true]; yield ['localhost', 'bento.dev', false];