diff --git a/test/parallel/test-gc-http-client-timeout.js b/test/parallel/test-gc-http-client-timeout.js index e6878021ef9b89..e5cb91c06f8911 100644 --- a/test/parallel/test-gc-http-client-timeout.js +++ b/test/parallel/test-gc-http-client-timeout.js @@ -39,7 +39,7 @@ function getall() { pathname: '/', port: server.address().port }, cb); - req.on('error', cb); + req.setTimeout(10, function() { console.log('timeout (expected)'); });