10000 include expected deprecations in assertion counter · symfony/symfony@cdcd5ae · GitHub
[go: up one dir, main page]

Skip to content

Commit cdcd5ae

Browse files
committed
include expected deprecations in assertion counter
1 parent 8d99d57 commit cdcd5ae

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Symfony/Bridge/PhpUnit/Legacy/SymfonyTestsListenerTrait.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,10 @@ public function endTest($test, $time)
240240
}
241241

242242
if ($this->expectedDeprecations) {
243+
if (!in_array($test->getStatus(), array($BaseTestRunner::STATUS_SKIPPED, $BaseTestRunner::STATUS_INCOMPLETE), true)) {
244+
$test->addToAssertionCount(count($this->expectedDeprecations));
245+
}
246+
243247
restore_error_handler();
244248

245249
if (!in_array($test->getStatus(), array($BaseTestRunner::STATUS_SKIPPED, $BaseTestRunner::STATUS_INCOMPLETE, $BaseTestRunner::STATUS_FAILURE, $BaseTestRunner::STATUS_ERROR), true)) {

0 commit comments

Comments
 (0)
0