From 98b70ea99fa1efdf423e1e9c01b06517a7acc1cb Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Sat, 8 Nov 2025 08:36:43 +0100 Subject: [PATCH 1/3] Add CoversNothing --- tests/PHPStan/Analyser/AnalyserIntegrationTest.php | 2 ++ tests/PHPStan/Command/AnalyseCommandTest.php | 2 ++ tests/PHPStan/Command/CommandHelperTest.php | 2 ++ .../BaselineNeonErrorFormatterIntegrationTest.php | 2 ++ tests/PHPStan/Generics/GenericsIntegrationTest.php | 2 ++ .../InferPrivatePropertyTypeFromConstructorIntegrationTest.php | 2 ++ tests/PHPStan/Levels/LevelsIntegrationTest.php | 1 + tests/PHPStan/Levels/NamedArgumentsIntegrationTest.php | 2 ++ tests/PHPStan/Levels/StubValidatorIntegrationTest.php | 2 ++ tests/PHPStan/Levels/StubsIntegrationTest.php | 2 ++ tests/PHPStan/Parallel/ParallelAnalyserIntegrationTest.php | 2 ++ 11 files changed, 21 insertions(+) diff --git a/tests/PHPStan/Analyser/AnalyserIntegrationTest.php b/tests/PHPStan/Analyser/AnalyserIntegrationTest.php index eb5d04b6df..9ffbc19566 100644 --- a/tests/PHPStan/Analyser/AnalyserIntegrationTest.php +++ b/tests/PHPStan/Analyser/AnalyserIntegrationTest.php @@ -11,11 +11,13 @@ use PHPStan\Testing\PHPStanTestCase; use PHPStan\Type\Constant\ConstantIntegerType; use PHPStan\Type\Constant\ConstantStringType; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\RequiresPhp; use function extension_loaded; use function sprintf; use const PHP_VERSION_ID; +#[CoversNothing] class AnalyserIntegrationTest extends PHPStanTestCase { diff --git a/tests/PHPStan/Command/AnalyseCommandTest.php b/tests/PHPStan/Command/AnalyseCommandTest.php index f2c4f4d73a..4eb75fc45c 100644 --- a/tests/PHPStan/Command/AnalyseCommandTest.php +++ b/tests/PHPStan/Command/AnalyseCommandTest.php @@ -4,6 +4,7 @@ use PHPStan\ShouldNotHappenException; use PHPStan\Testing\PHPStanTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\Attributes\Group; use Symfony\Component\Console\Tester\CommandTester; @@ -17,6 +18,7 @@ use const PHP_EOL; #[Group('exec')] +#[CoversNothing] class AnalyseCommandTest extends PHPStanTestCase { diff --git a/tests/PHPStan/Command/CommandHelperTest.php b/tests/PHPStan/Command/CommandHelperTest.php index 9b3813e054..a9c2c8414e 100644 --- a/tests/PHPStan/Command/CommandHelperTest.php +++ b/tests/PHPStan/Command/CommandHelperTest.php @@ -3,6 +3,7 @@ namespace PHPStan\Command; use PHPStan\ShouldNotHappenException; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; @@ -16,6 +17,7 @@ use const DIRECTORY_SEPARATOR; #[Group('exec')] +#[CoversNothing] class CommandHelperTest extends TestCase { diff --git a/tests/PHPStan/Command/ErrorFormatter/BaselineNeonErrorFormatterIntegrationTest.php b/tests/PHPStan/Command/ErrorFormatter/BaselineNeonErrorFormatterIntegrationTest.php index 4cab9de19b..107ff02a9d 100644 --- a/tests/PHPStan/Command/ErrorFormatter/BaselineNeonErrorFormatterIntegrationTest.php +++ b/tests/PHPStan/Command/ErrorFormatter/BaselineNeonErrorFormatterIntegrationTest.php @@ -4,6 +4,7 @@ use Nette\Utils\Json; use PHPStan\ShouldNotHappenException; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; use function array_sum; @@ -17,6 +18,7 @@ use const PHP_BINARY; #[Group('exec')] +#[CoversNothing] class BaselineNeonErrorFormatterIntegrationTest extends TestCase { diff --git a/tests/PHPStan/Generics/GenericsIntegrationTest.php b/tests/PHPStan/Generics/GenericsIntegrationTest.php index e8309a0846..b389aa8147 100644 --- a/tests/PHPStan/Generics/GenericsIntegrationTest.php +++ b/tests/PHPStan/Generics/GenericsIntegrationTest.php @@ -3,9 +3,11 @@ namespace PHPStan\Generics; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; #[Group('levels')] +#[CoversNothing] class GenericsIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Levels/InferPrivatePropertyTypeFromConstructorIntegrationTest.php b/tests/PHPStan/Levels/InferPrivatePropertyTypeFromConstructorIntegrationTest.php index 3338348583..5d7e37d1e4 100644 --- a/tests/PHPStan/Levels/InferPrivatePropertyTypeFromConstructorIntegrationTest.php +++ b/tests/PHPStan/Levels/InferPrivatePropertyTypeFromConstructorIntegrationTest.php @@ -3,9 +3,11 @@ namespace PHPStan\Levels; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; #[Group('levels')] +#[CoversNothing] class InferPrivatePropertyTypeFromConstructorIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Levels/LevelsIntegrationTest.php b/tests/PHPStan/Levels/LevelsIntegrationTest.php index 044a088f60..89ad5acd43 100644 --- a/tests/PHPStan/Levels/LevelsIntegrationTest.php +++ b/tests/PHPStan/Levels/LevelsIntegrationTest.php @@ -7,6 +7,7 @@ use const PHP_VERSION_ID; #[Group('levels')] +#[CoversNothing] class LevelsIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Levels/NamedArgumentsIntegrationTest.php b/tests/PHPStan/Levels/NamedArgumentsIntegrationTest.php index 999427f6c6..27347a4aa8 100644 --- a/tests/PHPStan/Levels/NamedArgumentsIntegrationTest.php +++ b/tests/PHPStan/Levels/NamedArgumentsIntegrationTest.php @@ -3,9 +3,11 @@ namespace PHPStan\Levels; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; #[Group('levels')] +#[CoversNothing] class NamedArgumentsIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Levels/StubValidatorIntegrationTest.php b/tests/PHPStan/Levels/StubValidatorIntegrationTest.php index d76d9045c0..96c2283441 100644 --- a/tests/PHPStan/Levels/StubValidatorIntegrationTest.php +++ b/tests/PHPStan/Levels/StubValidatorIntegrationTest.php @@ -3,9 +3,11 @@ namespace PHPStan\Levels; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; #[Group('levels')] +#[CoversNothing] class StubValidatorIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Levels/StubsIntegrationTest.php b/tests/PHPStan/Levels/StubsIntegrationTest.php index c8be90cd53..f58cfeadf2 100644 --- a/tests/PHPStan/Levels/StubsIntegrationTest.php +++ b/tests/PHPStan/Levels/StubsIntegrationTest.php @@ -3,9 +3,11 @@ namespace PHPStan\Levels; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; #[Group('levels')] +#[CoversNothing] class StubsIntegrationTest extends LevelsTestCase { diff --git a/tests/PHPStan/Parallel/ParallelAnalyserIntegrationTest.php b/tests/PHPStan/Parallel/ParallelAnalyserIntegrationTest.php index fb60543a17..eb52d3f335 100644 --- a/tests/PHPStan/Parallel/ParallelAnalyserIntegrationTest.php +++ b/tests/PHPStan/Parallel/ParallelAnalyserIntegrationTest.php @@ -6,6 +6,7 @@ use Nette\Utils\Json; use PHPStan\File\FileHelper; use PHPStan\ShouldNotHappenException; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; @@ -21,6 +22,7 @@ use const PHP_BINARY; #[Group('exec')] +#[CoversNothing] class ParallelAnalyserIntegrationTest extends TestCase { From 9fa48f91d88e091269754f2749c27719ab6c92ac Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Sat, 8 Nov 2025 08:44:47 +0100 Subject: [PATCH 2/3] Add to remaining *IntegrationTest classes --- tests/PHPStan/Analyser/AnalyserTraitsIntegrationTest.php | 2 ++ tests/PHPStan/Command/AnalyseApplicationIntegrationTest.php | 2 ++ 2 files changed, 4 insertions(+) diff --git a/tests/PHPStan/Analyser/AnalyserTraitsIntegrationTest.php b/tests/PHPStan/Analyser/AnalyserTraitsIntegrationTest.php index 914064439f..327ddb46a4 100644 --- a/tests/PHPStan/Analyser/AnalyserTraitsIntegrationTest.php +++ b/tests/PHPStan/Analyser/AnalyserTraitsIntegrationTest.php @@ -5,6 +5,7 @@ use Override; use PHPStan\File\FileHelper; use PHPStan\Testing\PHPStanTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\RequiresPhp; use function array_map; use function array_merge; @@ -12,6 +13,7 @@ use function sprintf; use function usort; +#[CoversNothing] class AnalyserTraitsIntegrationTest extends PHPStanTestCase { diff --git a/tests/PHPStan/Command/AnalyseApplicationIntegrationTest.php b/tests/PHPStan/Command/AnalyseApplicationIntegrationTest.php index b13cb49ef9..05962e07a6 100644 --- a/tests/PHPStan/Command/AnalyseApplicationIntegrationTest.php +++ b/tests/PHPStan/Command/AnalyseApplicationIntegrationTest.php @@ -13,6 +13,7 @@ use PHPStan\File\SimpleRelativePathHelper; use PHPStan\ShouldNotHappenException; use PHPStan\Testing\PHPStanTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\StreamOutput; use Symfony\Component\Console\Style\SymfonyStyle; @@ -22,6 +23,7 @@ use function stream_get_contents; use const DIRECTORY_SEPARATOR; +#[CoversNothing] class AnalyseApplicationIntegrationTest extends PHPStanTestCase { From 480be4bb9ff081e05dd2a20fe275a15342f0c0d4 Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Sat, 8 Nov 2025 09:08:14 +0100 Subject: [PATCH 3/3] Update LevelsIntegrationTest.php --- tests/PHPStan/Levels/LevelsIntegrationTest.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/PHPStan/Levels/LevelsIntegrationTest.php b/tests/PHPStan/Levels/LevelsIntegrationTest.php index 89ad5acd43..844e366fa9 100644 --- a/tests/PHPStan/Levels/LevelsIntegrationTest.php +++ b/tests/PHPStan/Levels/LevelsIntegrationTest.php @@ -3,6 +3,7 @@ namespace PHPStan\Levels; use PHPStan\Testing\LevelsTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; use PHPUnit\Framework\Attributes\Group; use const PHP_VERSION_ID;