GeezerVison is showing github.com — test: remove common.PORT from parallel tests · nodejs/node@53b702f
File treeExpand file treeCollapse file tree Open diff view settings Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: test/async-hooks/test-graph.tcp.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -15,7 +15,7 @@ const server = net | 15 | 15 | .createServer(common.mustCall(onconnection)) | 16 | 16 | .on('listening', common.mustCall(onlistening)); | 17 | 17 |
| 18 | | -server.listen(common.PORT); | | 18 | +server.listen(0); | 19 | 19 |
| 20 | 20 | net.connect({ port: server.address().port, host: '::1' }, | 21 | 21 | common.mustCall(onconnected)); | |
Collapse file Copy file name to clipboardExpand all lines: test/async-hooks/test-graph.tls-write.js +2-2Lines changed: 2 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -25,14 +25,14 @@ const server = tls | 25 | 25 | }) | 26 | 26 | .on('listening', common.mustCall(onlistening)) | 27 | 27 | .on('secureConnection', common.mustCall(onsecureConnection)) | 28 | | - .listen(common.PORT); | | 28 | + .listen(0); | 29 | 29 |
| 30 | 30 | function onlistening() { | 31 | 31 | // | 32 | 32 | // Creating client and connecting it to server | 33 | 33 | // | 34 | 34 | tls | 35 | | - .connect(common.PORT, { rejectUnauthorized: false }) | | 35 | + .connect(server.address().port, { rejectUnauthorized: false }) | 36 | 36 | .on('secureConnect', common.mustCall(onsecureConnect)); | 37 | 37 | } | 38 | 38 |
| |
Collapse file Copy file name to clipboardExpand all lines: test/async-hooks/test-tcpwrap.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -24,7 +24,7 @@ const server = net | 24 | 24 |
| 25 | 25 | // Calling server.listen creates a TCPWRAP synchronously | 26 | 26 | { | 27 | | - server.listen(common.PORT); | | 27 | + server.listen(0); | 28 | 28 | const tcpsservers = hooks.activitiesOfTypes('TCPSERVERWRAP'); | 29 | 29 | const tcpconnects = hooks.activitiesOfTypes('TCPCONNECTWRAP'); | 30 | 30 | assert.strictEqual(tcpsservers.length, 1); | |
Collapse file Copy file name to clipboardExpand all lines: test/async-hooks/test-writewrap.js +2-2Lines changed: 2 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -23,7 +23,7 @@ const server = tls | 23 | 23 | }) | 24 | 24 | .on('listening', common.mustCall(onlistening)) | 25 | 25 | .on('secureConnection', common.mustCall(onsecureConnection)) | 26 | | - .listen(common.PORT); | | 26 | + .listen(0); | 27 | 27 |
| 28 | 28 | assert.strictEqual(hooks.activitiesOfTypes('WRITEWRAP').length, 0); | 29 | 29 |
| @@ -33,7 +33,7 @@ function onlistening() { | 33 | 33 | // Creating client and connecting it to server | 34 | 34 | // | 35 | 35 | tls | 36 | | - .connect(common.PORT, { rejectUnauthorized: false }) | | 36 | + .connect(server.address().port, { rejectUnauthorized: false }) | 37 | 37 | .on('secureConnect', common.mustCall(onsecureConnect)); | 38 | 38 |
| 39 | 39 | assert.strictEqual(hooks.activitiesOfTypes('WRITEWRAP').length, 0); | |
Collapse file Copy file name to clipboardExpand all lines: test/parallel/test-net-connect-immediate-finish.js +2-2Lines changed: 2 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -38,9 +38,9 @@ const { | 38 | 38 |
| 39 | 39 | const client = net.connect({ | 40 | 40 | host: addresses.INVALID_HOST, | 41 | | - port: common.PORT, | | 41 | + port: 80, // port number doesn't matter because host name is invalid | 42 | 42 | lookup: common.mustCall(errorLookupMock()) | 43 | | -}); | | 43 | +}, common.mustNotCall()); | 44 | 44 |
| 45 | 45 | client.once('error', common.mustCall((err) => { | 46 | 46 | assert(err); | |
Collapse file Copy file name to clipboard File renamed without changes. Collapse file Copy file name to clipboard File renamed without changes.
|