test: skip test-dns-ipv6.js if ipv6 is unavailable
authorJunliang Yan <jyan@ca.ibm.ca>
Mon, 19 Oct 2015 19:30:11 +0000 (15:30 -0400)
committerJames M Snell <jasnell@gmail.com>
Thu, 29 Oct 2015 15:38:42 +0000 (08:38 -0700)
Test should be skipped if ipv6 is unavailable on the running system.

Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/3444

test/internet/test-dns-ipv6.js

index 27b25f7995e6309d2badefd06a0d1bc6da655210..5a66f8db783f4b41c0003b87039ca2165da6fde3 100644 (file)
@@ -12,6 +12,11 @@ var expected = 0,
     running = false,
     queue = [];
 
+if (!common.hasIPv6) {
+  console.log('1..0 # Skipped: this test, no IPv6 support');
+  return;
+}
+
 function TEST(f) {
   function next() {
     var f = queue.shift();