mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
test: utilize common.mustCall() on child exit
PR-URL: https://github.com/nodejs/node/pull/16996 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
This commit is contained in:
parent
6244070c48
commit
95d9a58cbc
@ -20,7 +20,7 @@
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
'use strict';
|
||||
require('../common');
|
||||
const common = require('../common');
|
||||
const assert = require('assert');
|
||||
const child_process = require('child_process');
|
||||
const spawn = child_process.spawn;
|
||||
@ -43,7 +43,7 @@ if (process.argv[2] === 'fork') {
|
||||
out += chunk;
|
||||
});
|
||||
|
||||
child.on('exit', function() {
|
||||
child.on('exit', common.mustCall(function() {
|
||||
assert.deepStrictEqual(JSON.parse(out), execArgv);
|
||||
});
|
||||
}));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user