Skip to content

Commit a804026

Browse files
santigimenobrendanashworth
authored andcommitted
test: fix broken FreeBSD test
Fixes net-server-max-connections-close-makes-more-available Handles connection 'error' event so the test ends. PR-URL: #1881 Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Brendan Ashworth <[email protected]>
1 parent 43a82f8 commit a804026

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

test/parallel/test-net-server-max-connections-close-makes-more-available.js

+5
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ var createConnection = function(index) {
2828
sent.push(msg);
2929
});
3030

31+
connection.on('error', function(err) {
32+
assert.equal(err.code, 'ECONNRESET');
33+
resolve();
34+
});
35+
3136
connection.on('data', function(e) {
3237
console.error('connection ' + index + ' received response');
3338
resolve();

0 commit comments

Comments
 (0)