Skip to content

Commit

Permalink
Update PHPUnit compatibility to 10.0.17 (#744)
Browse files Browse the repository at this point in the history
  • Loading branch information
Slamdunk authored Mar 20, 2023
1 parent abc1231 commit 10e66cc
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 8 deletions.
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"phpunit/php-code-coverage": "^10.0.2",
"phpunit/php-file-iterator": "^4.0.1",
"phpunit/php-timer": "^6.0",
"phpunit/phpunit": "^10.0.16",
"phpunit/phpunit": "^10.0.17",
"sebastian/environment": "^6.0",
"symfony/console": "^6.2.7",
"symfony/process": "^6.2.7"
Expand All @@ -53,8 +53,8 @@
"ext-posix": "*",
"doctrine/coding-standard": "^11.1.0",
"infection/infection": "^0.26.19",
"phpstan/phpstan": "^1.10.6",
"phpstan/phpstan-deprecation-rules": "^1.1.2",
"phpstan/phpstan": "^1.10.7",
"phpstan/phpstan-deprecation-rules": "^1.1.3",
"phpstan/phpstan-phpunit": "^1.3.10",
"phpstan/phpstan-strict-rules": "^1.5",
"squizlabs/php_codesniffer": "^3.7.2",
Expand Down
15 changes: 11 additions & 4 deletions src/WrapperRunner/ApplicationForWrapperWorker.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,25 +118,32 @@ private function bootstrap(): void
CodeCoverage::instance()->init($this->configuration, CodeCoverageFilterRegistry::instance());

if ($this->configuration->hasLogfileJunit()) {
new JunitXmlLogger(DefaultPrinter::from($this->configuration->logfileJunit()));
new JunitXmlLogger(
DefaultPrinter::from($this->configuration->logfileJunit()),
EventFacade::instance(),
);
}

new ProgressPrinter(
DefaultPrinter::from($this->progressFile),
false,
120,
EventFacade::instance(),
);

if (isset($this->teamcityFile)) {
new TeamCityLogger(DefaultPrinter::from($this->teamcityFile));
new TeamCityLogger(
DefaultPrinter::from($this->teamcityFile),
EventFacade::instance(),
);
}

if (isset($this->testdoxFile)) {
$this->testdoxResultCollector = new TestResultCollector();
$this->testdoxResultCollector = new TestResultCollector(EventFacade::instance());
}

TestResultFacade::init();
EventFacade::seal();
EventFacade::instance()->seal();
EventFacade::emitter()->testRunnerStarted();

if ($this->configuration->executionOrder() === TestSuiteSorter::ORDER_RANDOMIZED) {
Expand Down
2 changes: 1 addition & 1 deletion src/WrapperRunner/WrapperRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public function run(): int
assert($directory !== '');
ExcludeList::addDirectory($directory);
TestResultFacade::init();
EventFacade::seal();
EventFacade::instance()->seal();
$suiteLoader = new SuiteLoader(
$this->options,
$this->output,
Expand Down

0 comments on commit 10e66cc

Please sign in to comment.