summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorsreepurnajasti <sreepurna.jasti@gmail.com>2017-11-13 21:24:52 +0530
committerAnna Henningsen <anna@addaleax.net>2017-11-18 20:49:36 +0100
commit95d9a58cbc13761087180c85c042b2e9cf1595e9 (patch)
tree8645f7d5cbb3709c6637d331730185b835280bd8 /test
parent6244070c48e96c25b5ab645de15da72e0cb8c3dc (diff)
downloadnode-new-95d9a58cbc13761087180c85c042b2e9cf1595e9.tar.gz
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>
Diffstat (limited to 'test')
-rw-r--r--test/parallel/test-child-process-fork-exec-argv.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/parallel/test-child-process-fork-exec-argv.js b/test/parallel/test-child-process-fork-exec-argv.js
index 433f83b35e..f1e3bbbc58 100644
--- a/test/parallel/test-child-process-fork-exec-argv.js
+++ b/test/parallel/test-child-process-fork-exec-argv.js
@@ -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);
- });
+ }));
}