Skip to content

Commit

Permalink
fix: test
Browse files Browse the repository at this point in the history
  • Loading branch information
yamadashy committed Sep 24, 2023
1 parent 7010776 commit f8a6548
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/FriendlyErrorFormatterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -236,13 +236,19 @@ private function getDummyAnalysisResult(int $numFileErrors, int $numGenericError
return new \PHPStan\Command\AnalysisResult($fileErrors, $genericErrors, [], $warnings, false, null, true);
}

// compatibility to less than 1.11.0
// compatibility to less than 1.9.0
if (8 === $numOfParams) {
// @phpstan-ignore-next-line
return new \PHPStan\Command\AnalysisResult($fileErrors, $genericErrors, [], $warnings, [], false, null, true);
}

// compatibility to less than 1.10.34
if (9 === $numOfParams) {
// @phpstan-ignore-next-line
return new \PHPStan\Command\AnalysisResult($fileErrors, $genericErrors, [], $warnings, [], false, null, true, memory_get_peak_usage(true));
}

// @phpstan-ignore-next-line
return new \PHPStan\Command\AnalysisResult($fileErrors, $genericErrors, [], $warnings, [], false, null, true, memory_get_peak_usage(true));
return new \PHPStan\Command\AnalysisResult($fileErrors, $genericErrors, [], $warnings, [], false, null, true, memory_get_peak_usage(true), false);
}
}

0 comments on commit f8a6548

Please sign in to comment.