Permalink
Browse files

Fix failing os.getNetworkInterfaces() test in test-os.js

  • Loading branch information...
1 parent 95b409c commit 56db5bf67772e45b127cd35fb93855eb1c31063b @bnoordhuis committed Jun 17, 2011
Showing with 4 additions and 1 deletion.
  1. +4 −1 test/simple/test-os.js
@@ -64,6 +64,9 @@ var interfaces = os.getNetworkInterfaces();
console.error(interfaces);
switch (platform) {
case 'linux':
- assert.equal('127.0.0.1', interfaces.lo.ip);
+ var filter = function(e) { return e.address == '127.0.0.1'; };
+ var actual = interfaces.lo.filter(filter);
+ var expected = [{ address: '127.0.0.1', family: 'IPv4', internal: true }];
+ assert.deepEqual(actual, expected);
break;
}

0 comments on commit 56db5bf

Please sign in to comment.