diff --git a/Makefile b/Makefile index 2851025e..082a4b18 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,7 @@ all: csfix static-analysis code-coverage vendor: composer.json composer update - #composer bump + composer bump touch vendor .PHONY: csfix diff --git a/composer.json b/composer.json index dd803d70..7c1f46d6 100644 --- a/composer.json +++ b/composer.json @@ -38,12 +38,12 @@ "ext-pcre": "*", "ext-reflection": "*", "ext-simplexml": "*", - "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", + "fidry/cpu-core-counter": "^0.5.1", "jean85/pretty-package-versions": "^2.0.5", - "phpunit/php-code-coverage": "^10.1.3", - "phpunit/php-file-iterator": "^4.0.2", + "phpunit/php-code-coverage": "^10.1.7", + "phpunit/php-file-iterator": "^4.1.0", "phpunit/php-timer": "^6.0", - "phpunit/phpunit": "^10.3.2", + "phpunit/phpunit": "^10.4.0", "sebastian/environment": "^6.0.1", "symfony/console": "^6.3.4", "symfony/process": "^6.3.4" @@ -52,8 +52,8 @@ "ext-pcov": "*", "ext-posix": "*", "doctrine/coding-standard": "^12.0.0", - "infection/infection": "^0.27.0", - "phpstan/phpstan": "^1.10.32", + "infection/infection": "^0.27.3", + "phpstan/phpstan": "^1.10.37", "phpstan/phpstan-deprecation-rules": "^1.1.4", "phpstan/phpstan-phpunit": "^1.3.14", "phpstan/phpstan-strict-rules": "^1.5.1", diff --git a/src/ParaTestCommand.php b/src/ParaTestCommand.php index 14f42dab..53250d11 100644 --- a/src/ParaTestCommand.php +++ b/src/ParaTestCommand.php @@ -80,7 +80,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int $input, $this->cwd, ); - if (! $options->configuration->hasConfigurationFile() && ! $options->configuration->hasCliArgument()) { + if (! $options->configuration->hasConfigurationFile() && ! $options->configuration->hasCliArguments()) { return $this->displayHelp($output); } diff --git a/src/WrapperRunner/ApplicationForWrapperWorker.php b/src/WrapperRunner/ApplicationForWrapperWorker.php index 31dab0eb..3e2f3724 100644 --- a/src/WrapperRunner/ApplicationForWrapperWorker.php +++ b/src/WrapperRunner/ApplicationForWrapperWorker.php @@ -70,7 +70,9 @@ public function runTest(string $testPath): int $filter = null; if ($null !== false) { $filter = new Factory(); - $filter->addNameFilter(substr($testPath, $null + 1)); + $name = substr($testPath, $null + 1); + assert($name !== ''); + $filter->addNameFilter($name); $testPath = substr($testPath, 0, $null); } diff --git a/src/WrapperRunner/WrapperRunner.php b/src/WrapperRunner/WrapperRunner.php index 3de6e498..0b20911c 100644 --- a/src/WrapperRunner/WrapperRunner.php +++ b/src/WrapperRunner/WrapperRunner.php @@ -280,6 +280,7 @@ private function complete(TestResult $testResultSum): int array_merge_recursive($testResultSum->phpDeprecations(), $testResult->phpDeprecations()), array_merge_recursive($testResultSum->phpNotices(), $testResult->phpNotices()), array_merge_recursive($testResultSum->phpWarnings(), $testResult->phpWarnings()), + $testResultSum->numberOfIssuesIgnoredByBaseline() + $testResult->numberOfIssuesIgnoredByBaseline(), ); } diff --git a/test/Unit/OptionsTest.php b/test/Unit/OptionsTest.php index 2503e2c4..fc828b5e 100644 --- a/test/Unit/OptionsTest.php +++ b/test/Unit/OptionsTest.php @@ -97,7 +97,7 @@ public function testProvidedOptions(): void self::assertSame(5, $options->maxBatchSize); self::assertTrue($options->noTestTokens); self::assertSame(['-d', 'a=1'], $options->passthruPhp); - self::assertSame('PATH', $options->configuration->cliArgument()); + self::assertSame('PATH', $options->configuration->cliArguments()[0]); self::assertSame(999, $options->processes); self::assertSame('MYRUNNER', $options->runner); self::assertSame($tmpDir, $options->tmpDir); diff --git a/test/Unit/WrapperRunner/ResultPrinterTest.php b/test/Unit/WrapperRunner/ResultPrinterTest.php index 1d198e9a..fa770262 100644 --- a/test/Unit/WrapperRunner/ResultPrinterTest.php +++ b/test/Unit/WrapperRunner/ResultPrinterTest.php @@ -374,6 +374,7 @@ private function getEmptyTestResult(): TestResult [], [], [], + 0, ); } }