test: fix async-hooks tests

The 'test-graph.tcp' and 'test-tcpwrap' tests are using '::' as server
address. This is mapped to localhost on Linux, but fails on Windows.

PR-URL: https://github.com/nodejs/node/pull/14865
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
This commit is contained in:
Bartosz Sosnowski 2017-08-17 19:18:06 +02:00 committed by Jeremiah Senkpiel
parent ca9b3f27eb
commit 88b85925fe
2 changed files with 2 additions and 2 deletions

View File

@ -17,7 +17,7 @@ const server = net
server.listen(common.PORT);
net.connect({ port: server.address().port, host: server.address().address },
net.connect({ port: server.address().port, host: '::1' },
common.mustCall(onconnected));
function onlistening() {}

View File

@ -38,7 +38,7 @@ const server = net
// Calling net.connect creates another TCPWRAP synchronously
{
net.connect(
{ port: server.address().port, host: server.address().address },
{ port: server.address().port, host: '::1' },
common.mustCall(onconnected));
const tcps = hooks.activitiesOfTypes('TCPWRAP');
assert.strictEqual(tcps.length, 2);