We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 86f49e2 commit fd9d510Copy full SHA for fd9d510
src/CodeCoverage/Generators/CloverXMLGenerator.php
@@ -92,7 +92,11 @@ protected function renderSelf(): void
92
$elFile->setAttribute('name', $file);
93
$elFileMetrics = $elFile->appendChild($doc->createElement('metrics'));
94
95
- $code = $parser->parse(file_get_contents($file));
+ try {
96
+ $code = $parser->parse(file_get_contents($file));
97
+ } catch (\ParseError $e) {
98
+ throw new \ParseError($e->getMessage() . ' in file ' . $file);
99
+ }
100
101
$fileMetrics = (object) [
102
'linesOfCode' => $code->linesOfCode,
0 commit comments