Skip to content

Commit

Permalink
fix: parse errors in coverage command (#156837)
Browse files Browse the repository at this point in the history
Fixes #155615
  • Loading branch information
connor4312 authored Aug 5, 2022
1 parent 31cc3b8 commit 39e77d7
Show file tree
Hide file tree
Showing 3 changed files with 277 additions and 135 deletions.
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -170,11 +170,11 @@
"husky": "^0.13.1",
"innosetup": "6.0.5",
"is": "^3.1.0",
"istanbul-lib-coverage": "^3.0.0",
"istanbul-lib-instrument": "^4.0.0",
"istanbul-lib-coverage": "^3.2.0",
"istanbul-lib-instrument": "^5.2.0",
"istanbul-lib-report": "^3.0.0",
"istanbul-lib-source-maps": "^4.0.0",
"istanbul-reports": "^3.0.0",
"istanbul-lib-source-maps": "^4.0.1",
"istanbul-reports": "^3.1.5",
"lazy.js": "^0.4.2",
"merge-options": "^1.0.1",
"mime": "^1.4.1",
Expand Down
7 changes: 6 additions & 1 deletion test/unit/coverage.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ exports.initialize = function (loaderConfig) {
} catch (err) {
// missing source map...
}
return instrumenter.instrumentSync(contents, source, map);
try {
return instrumenter.instrumentSync(contents, source, map);
} catch (e) {
console.error(`Error instrumenting ${source}: ${e}`);
throw e;
}
};
};

Expand Down
Loading

0 comments on commit 39e77d7

Please sign in to comment.