From 4e78cd71c00d0f109f414bcc01160be3704a4bb4 Mon Sep 17 00:00:00 2001 From: Sakthipriyan Vairamani Date: Thu, 23 Jul 2015 01:28:30 +0530 Subject: [PATCH] test: skip IPv6 part before testing it PR-URL: https://github.com/nodejs/io.js/pull/2226 Reviewed-By: Colin Ihrig Reviewed-By: Roman Reiss --- test/sequential/test-net-server-address.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/sequential/test-net-server-address.js b/test/sequential/test-net-server-address.js index 8c57cb742e2d02..ddc65c2df2b828 100644 --- a/test/sequential/test-net-server-address.js +++ b/test/sequential/test-net-server-address.js @@ -19,6 +19,11 @@ server_ipv4.listen(common.PORT, common.localhostIPv4, function() { server_ipv4.close(); }); +if (!common.hasIPv6) { + console.log('1..0 # Skipped: ipv6 part of test, no IPv6 support'); + return; +} + // Test on IPv6 Server var localhost_ipv6 = '::1'; var family_ipv6 = 'IPv6'; @@ -36,11 +41,6 @@ server_ipv6.listen(common.PORT, localhost_ipv6, function() { server_ipv6.close(); }); -if (!common.hasIPv6) { - console.log('1..0 # Skipped: ipv6 part of test, no IPv6 support'); - return; -} - // Test without hostname or ip var anycast_ipv6 = '::'; var server1 = net.createServer();