Skip to content

Commit a92f3df

Browse files
Trottjasnell
authored andcommittedSep 20, 2017
test: make test-http-agent-maxsockets robust
On a slow/busy machine, `test-http-agent-maxsockets` can fail if the test takes longer than 5 seconds because that is the default value for `server.keepAliveTimeout`. Disable `keepAliveTimeout` to make the test robust. PR-URL: #15192 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Tobias Nießen <[email protected]>
1 parent edece30 commit a92f3df

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed
 

‎test/parallel/test-http-agent-maxsockets.js

+2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ const server = http.createServer(common.mustCall((req, res) => {
1515
res.end('hello world');
1616
}, 2));
1717

18+
server.keepAliveTimeout = 0;
19+
1820
function get(path, callback) {
1921
return http.get({
2022
host: 'localhost',

0 commit comments

Comments
 (0)
Please sign in to comment.