Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: use dynamic port in test-tls-connect.js #14687

Closed
wants to merge 1 commit into from

Conversation

oantoro
Copy link
Contributor

@oantoro oantoro commented Aug 8, 2017

Usage of common.PORT in parallel tests is not completely safe

Change common.PORT to dynamic port to prevent collision
with other parallel test which use common.PORT

Refs: #12376

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test

Change common.PORT to dynamic port to prevent collision
with other parallel test which use common.PORT

Refs: [nodejs#12376](nodejs#12376)
@nodejs-github-bot nodejs-github-bot added the test Issues and PRs related to the tests. label Aug 8, 2017
@mscdex mscdex added the tls Issues and PRs related to the tls subsystem. label Aug 8, 2017
@Trott
Copy link
Member

Trott commented Aug 8, 2017

Hi, @okyantoro! Welcome.

Listening on port 0 assigns an arbitrary port. Connecting to port 0 does not make any sense and results in an error. The test with your changes fail because the test cases expect connection failure, but now they are failing for the wrong reason. (I'll update the tests so no one else falls into this trap.)

I'm going to close this out as this is not the path to solving this problem. Feel free to re-open or open a separate pull request if you want to try a different approach.

Thanks!

@Trott Trott closed this Aug 8, 2017
@oantoro oantoro deleted the common-port branch August 8, 2017 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test Issues and PRs related to the tests. tls Issues and PRs related to the tls subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants