Skip to content

Commit

Permalink
test, win: fix IPv6 detection on Windows
Browse files Browse the repository at this point in the history
Add proper IPv6 detection on loopback device on Windows.

PR-URL: #14865
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
  • Loading branch information
bzoz authored and MylesBorins committed Sep 12, 2017
1 parent 1849c51 commit 4d6da3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/common/index.js
Expand Up @@ -262,7 +262,7 @@ Object.defineProperty(exports, 'hasFipsCrypto', {


{ {
const iFaces = os.networkInterfaces(); const iFaces = os.networkInterfaces();
const re = /lo/; const re = exports.isWindows ? /Loopback Pseudo-Interface/ : /lo/;
exports.hasIPv6 = Object.keys(iFaces).some(function(name) { exports.hasIPv6 = Object.keys(iFaces).some(function(name) {
return re.test(name) && iFaces[name].some(function(info) { return re.test(name) && iFaces[name].some(function(info) {
return info.family === 'IPv6'; return info.family === 'IPv6';
Expand Down

0 comments on commit 4d6da3f

Please sign in to comment.