Skip to content

Commit

Permalink
test: don't skip when common.mustCall() is pending
Browse files Browse the repository at this point in the history
The test parallel/test-dgram-multicast-set-interface.js was
calling common.skip() on hosts that do not support IPv6. However,
by this point, there were several outstanding common.mustCall()
invocations. The process.exit() in common.skip() triggered
those common.mustCall()s as errors.

Fixes: #15419
PR-URL: #15421
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
  • Loading branch information
cjihrig authored and jasnell committed Sep 20, 2017
1 parent 87a3162 commit ba96c8f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/parallel/test-dgram-multicast-set-interface.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,11 @@ const dgram = require('dgram');
}));
}

if (!common.hasIPv6) {
common.skip('Skipping udp6 tests, no IPv6 support.');
// If IPv6 is not supported, skip the rest of the test. However, don't call
// common.skip(), which calls process.exit() while there is outstanding
// common.mustCall() activity.
if (!common.hasIPv6)
return;
}

{
const socket = dgram.createSocket('udp6');
Expand Down

0 comments on commit ba96c8f

Please sign in to comment.