summaryrefslogtreecommitdiff
path: root/test/parallel/test-net-connect-options-ipv6.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/parallel/test-net-connect-options-ipv6.js')
-rw-r--r--test/parallel/test-net-connect-options-ipv6.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/test/parallel/test-net-connect-options-ipv6.js b/test/parallel/test-net-connect-options-ipv6.js
index 6ac6c29e10..29b07645c4 100644
--- a/test/parallel/test-net-connect-options-ipv6.js
+++ b/test/parallel/test-net-connect-options-ipv6.js
@@ -21,14 +21,12 @@
'use strict';
const common = require('../common');
+if (!common.hasIPv6)
+ common.skip('no IPv6 support');
+
const assert = require('assert');
const net = require('net');
-if (!common.hasIPv6) {
- common.skip('no IPv6 support');
- return;
-}
-
const hosts = common.localIPv6Hosts;
let hostIdx = 0;
let host = hosts[hostIdx];
@@ -81,8 +79,8 @@ function tryConnect() {
if (host)
tryConnect();
else {
- common.skip('no IPv6 localhost support');
server.close();
+ common.skip('no IPv6 localhost support');
}
return;
}