Browse Source

test: fix child-process-fork-regr-gh-2847 again

Windows is still sometimes failing with ECONNRESET. Bring back the
handling of this error as was initially introduced in PR #4442.

PR-URL: https://github.com/nodejs/node/pull/5179
Reviewed-By: Rich Trott <rtrott@gmail.com>
Fixes: https://github.com/nodejs/node/issues/3635
process-exit-stdio-flushing
Santiago Gimeno 9 years ago
committed by Rich Trott
parent
commit
24667eeff8
  1. 7
      test/parallel/test-child-process-fork-regr-gh-2847.js

7
test/parallel/test-child-process-fork-regr-gh-2847.js

@ -15,6 +15,13 @@ if (!cluster.isMaster) {
}
var server = net.createServer(function(s) {
if (common.isWindows) {
s.on('error', function(err) {
// Prevent possible ECONNRESET errors from popping up
if (err.code !== 'ECONNRESET')
throw err;
});
}
setTimeout(function() {
s.destroy();
}, 100);

Loading…
Cancel
Save