Skip to content

Commit

Permalink
test: use dynamic port in test-tls-connect.js
Browse files Browse the repository at this point in the history
Change common.PORT to dynamic port to prevent collision
with other parallel test which use common.PORT

Refs: [nodejs#12376](nodejs#12376)
  • Loading branch information
oantoro committed Aug 8, 2017
1 parent c3c045a commit 71a8dc2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/parallel/test-tls-connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const path = require('path');
const cert = fs.readFileSync(path.join(common.fixturesDir, 'test_cert.pem'));
const key = fs.readFileSync(path.join(common.fixturesDir, 'test_key.pem'));

const options = { cert: cert, key: key, port: common.PORT };
const options = { cert: cert, key: key, port: 0 };
const conn = tls.connect(options, common.mustNotCall());

conn.on('error', common.mustCall());
Expand All @@ -49,7 +49,7 @@ const path = require('path');
const conn = tls.connect({
cert: cert,
key: key,
port: common.PORT,
port: 0,
ciphers: 'rick-128-roll'
}, common.mustNotCall());

Expand Down

0 comments on commit 71a8dc2

Please sign in to comment.