Skip to content

Commit

Permalink
coverage: use process._rawDebug() during setup
Browse files Browse the repository at this point in the history
console is not ready to use at this point in the bootstrapping
process, so switch to process._rawDebug() instead.

PR-URL: nodejs#25289
Fixes: nodejs#25287
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Gus Caplan <[email protected]>
Reviewed-By: Yuta Hiroto <[email protected]>
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
cjihrig committed Jan 2, 2019
1 parent 49672f4 commit d32f769
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/internal/process/coverage.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ exports.writeCoverage = writeCoverage;
function setup() {
const { Connection } = internalBinding('inspector');
if (!Connection) {
console.warn('inspector not enabled');
process._rawDebug('inspector not enabled');
return;
}

Expand All @@ -80,7 +80,7 @@ function setup() {
coverageDirectory = process.env.NODE_V8_COVERAGE =
resolve(process.env.NODE_V8_COVERAGE);
} catch (err) {
console.error(err);
process._rawDebug(err.toString());
}
}

Expand Down

0 comments on commit d32f769

Please sign in to comment.