diff --git a/src/Plugins/Parallel/Paratest/WrapperRunner.php b/src/Plugins/Parallel/Paratest/WrapperRunner.php index 7424152e..13eb1737 100644 --- a/src/Plugins/Parallel/Paratest/WrapperRunner.php +++ b/src/Plugins/Parallel/Paratest/WrapperRunner.php @@ -369,12 +369,14 @@ final class WrapperRunner implements RunnerInterface { $this->debug(sprintf('Found %d test file%s', count($suiteLoader->files), count($suiteLoader->files) === 1 ? '' : 's')); - $tests = array_filter( + $phpunitTests = array_filter( $suiteLoader->files, fn (string $filename): bool => ! str_ends_with($filename, "eval()'d code") ); - return [...$tests, ...TestSuite::getInstance()->tests->getFilenames()]; + $pestTests = TestSuite::getInstance()->tests->getFilenames(); + + return [...$phpunitTests, ...$pestTests]; } private function debug(string $message): void diff --git a/tests/PHPUnit/CustomTestCaseInSubFolders/SubFolder/SubFolder/UsesPerSubDirectory.php b/tests/PHPUnit/CustomTestCaseInSubFolders/SubFolder/SubFolder/UsesPerSubDirectory.php index 01bb8456..3136a08b 100644 --- a/tests/PHPUnit/CustomTestCaseInSubFolders/SubFolder/SubFolder/UsesPerSubDirectory.php +++ b/tests/PHPUnit/CustomTestCaseInSubFolders/SubFolder/SubFolder/UsesPerSubDirectory.php @@ -2,4 +2,4 @@ test('closure was bound to CustomTestCase', function () { $this->assertCustomInSubFolderTrue(); -}); +})->only();