Skip to content

Commit

Permalink
Merge branch '7.5' into 8.4
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianbergmann committed Oct 28, 2019
2 parents f9f77ec + ea510c5 commit a498029
Showing 1 changed file with 8 additions and 14 deletions.
22 changes: 8 additions & 14 deletions src/Framework/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -1957,23 +1957,17 @@ private function verifyMockObjects(): void
if ($this->prophet !== null) {
try {
$this->prophet->checkPredictions();
} catch (\Throwable $t) {
/* Intentionally left empty */
}

foreach ($this->prophet->getProphecies() as $objectProphecy) {
foreach ($objectProphecy->getMethodProphecies() as $methodProphecies) {
foreach ($methodProphecies as $methodProphecy) {
\assert($methodProphecy instanceof MethodProphecy);

$this->numAssertions += \count($methodProphecy->getCheckedPredictions());
} finally {
foreach ($this->prophet->getProphecies() as $objectProphecy) {
foreach ($objectProphecy->getMethodProphecies() as $methodProphecies) {
foreach ($methodProphecies as $methodProphecy) {
\assert($methodProphecy instanceof MethodProphecy);

$this->numAssertions += \count($methodProphecy->getCheckedPredictions());
}
}
}
}

if (isset($t)) {
throw $t;
}
}
}

Expand Down

0 comments on commit a498029

Please sign in to comment.