Skip to content

Commit

Permalink
test: fix test-process-exec-argv flakiness
Browse files Browse the repository at this point in the history
Wait for the `close` event before parsing the child stdout output.

Fixes: #6480
PR-URL: #6575
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
  • Loading branch information
santigimeno committed May 12, 2016
1 parent 0e2b250 commit dffafde
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/parallel/test-process-exec-argv.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ if (process.argv[2] === 'child') {
out += chunk;
});

child.on('exit', function() {
child.on('close', function() {
assert.deepStrictEqual(JSON.parse(out), execArgv);
});
}

0 comments on commit dffafde

Please sign in to comment.