| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent f21ed3a commit e585a11
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -31,8 +31,6 @@ test-crypto-dh-stateless: SKIP | |||
| 31 | 31 | test-crypto-keygen: SKIP | |
| 32 | 32 | ||
| 33 | 33 | [$system==solaris] # Also applies to SmartOS | |
| 34 | - # https://github.com/nodejs/node/issues/43446 | ||
| 35 | - test-net-connect-reset-until-connected: PASS, FLAKY | ||
| 36 | 34 | # https://github.com/nodejs/node/issues/43457 | |
| 37 | 35 | test-domain-no-error-handler-abort-on-uncaught-0: PASS, FLAKY | |
| 38 | 36 | test-domain-no-error-handler-abort-on-uncaught-1: PASS,FLAKY | |
@@ -52,8 +50,6 @@ test-domain-with-abort-on-uncaught-exception: PASS, FLAKY | |||
| 52 | 50 | test-fs-stat-bigint: PASS,FLAKY | |
| 53 | 51 | # https://github.com/nodejs/node/issues/31280 | |
| 54 | 52 | test-worker-message-port-message-before-close: PASS,FLAKY | |
| 55 | - # https://github.com/nodejs/node/issues/43446 | ||
| 56 | - test-net-connect-reset-until-connected: PASS, FLAKY | ||
| 57 | 53 | ||
| 58 | 54 | [$system==ibmi] | |
| 59 | 55 | # https://github.com/nodejs/node/pull/30819 | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3,18 +3,27 @@ | |||
| 3 | 3 | const common = require('../common'); | |
| 4 | 4 | const net = require('net'); | |
| 5 | 5 | ||
| 6 | + function barrier(count, cb) { | ||
| 7 | + return function() { | ||
| 8 | + if (--count === 0) | ||
| 9 | + cb(); | ||
| 10 | + }; | ||
| 11 | + } | ||
| 12 | + | ||
| 6 | 13 | const server = net.createServer(); | |
| 7 | 14 | server.listen(0, common.mustCall(function() { | |
| 8 | 15 | const port = server.address().port; | |
| 9 | 16 | const conn = net.createConnection(port); | |
| 17 | + const connok = barrier(2, () => conn.resetAndDestroy()); | ||
| 10 | 18 | conn.on('close', common.mustCall()); | |
| 11 | 19 | server.on('connection', (socket) => { | |
| 20 | + connok(); | ||
| 12 | 21 | socket.on('error', common.expectsError({ | |
| 13 | 22 | code: 'ECONNRESET', | |
| 14 | 23 | message: 'read ECONNRESET', | |
| 15 | 24 | name: 'Error' | |
| 16 | 25 | })); | |
| 17 | 26 | server.close(); | |
| 18 | 27 | }); | |
| 19 | - conn.resetAndDestroy(); | ||
| 28 | + conn.on('connect', connok); | ||
| 20 | 29 | })); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments