Skip to content

Commit

Permalink
test: replace console.log() with debuglog()
Browse files Browse the repository at this point in the history
PR-URL: #32550
Refs: #32541
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Yongsheng Zhang <[email protected]>
  • Loading branch information
juanarbol authored and targos committed Apr 11, 2020
1 parent 408437d commit 8f0c106
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/parallel/test-process-exit-code.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'use strict';
require('../common');
const assert = require('assert');
const debug = require('util').debuglog('test');

const testCases = require('../fixtures/process-exit-code-cases');

Expand All @@ -30,7 +31,7 @@ if (!process.argv[2]) {
} else {
const i = parseInt(process.argv[2]);
if (Number.isNaN(i)) {
console.log('Invalid test case index');
debug('Invalid test case index');
process.exit(100);
return;
}
Expand All @@ -48,7 +49,7 @@ function parent() {
assert.strictEqual(
code, exit,
`wrong exit for ${arg}-${name}\nexpected:${exit} but got:${code}`);
console.log(`ok - ${arg} exited with ${exit}`);
debug(`ok - ${arg} exited with ${exit}`);
});
};

Expand Down

0 comments on commit 8f0c106

Please sign in to comment.