diff --git a/test/parallel/test-net-pingpong.js b/test/parallel/test-net-pingpong.js index 29652ec0d1c6ce..3bbe076b4b1658 100644 --- a/test/parallel/test-net-pingpong.js +++ b/test/parallel/test-net-pingpong.js @@ -130,4 +130,4 @@ const tmpdir = require('../common/tmpdir'); tmpdir.refresh(); pingPongTest(common.PIPE); pingPongTest(0); -common.hasIPv6 ? pingPongTest(0, '::1') : pingPongTest(0, '127.0.0.1'); +if (common.hasIPv6) pingPongTest(0, '::1'); else pingPongTest(0, '127.0.0.1'); diff --git a/test/parallel/test-net-remote-address-port.js b/test/parallel/test-net-remote-address-port.js index a3ad67d9f9ec6e..fe090a3aa7a580 100644 --- a/test/parallel/test-net-remote-address-port.js +++ b/test/parallel/test-net-remote-address-port.js @@ -34,10 +34,10 @@ const remoteFamilyCandidates = ['IPv4']; if (common.hasIPv6) remoteFamilyCandidates.push('IPv6'); const server = net.createServer(common.mustCall(function(socket) { - // test to see real value in CI log + // Test to see real value in CI log assert.match(socket.remoteAddress, - /^127\.0\.0\.1$|^::1$|^::ffff:127.0.0.1$/); - // assert.ok(remoteAddrCandidates.includes(socket.remoteAddress)); + /^127\.0\.0\.1$|^::1$|^::ffff:127\.0\.0\.1$/); + // REM: assert.ok(remoteAddrCandidates.includes(socket.remoteAddress)); assert.ok(remoteFamilyCandidates.includes(socket.remoteFamily)); assert.ok(socket.remotePort); assert.notStrictEqual(socket.remotePort, this.address().port); diff --git a/test/pummel/test-net-pingpong.js b/test/pummel/test-net-pingpong.js index 10c7a36fc4afe5..c5ada54fcecd74 100644 --- a/test/pummel/test-net-pingpong.js +++ b/test/pummel/test-net-pingpong.js @@ -112,7 +112,7 @@ function pingPongTest(host, on_complete) { // All are run at once and will run on different ports. pingPongTest(null); -common.hasIPv6 ? pingPongTest('::1') : pingPongTest('127.0.0.1'); +if (common.hasIPv6) pingPongTest('::1'); else pingPongTest('127.0.0.1'); process.on('exit', function() { assert.strictEqual(tests_run, common.hasIPv6 ? 3 : 2);