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: have inspector test pick an open port #10861

Merged
merged 1 commit into from
Jan 19, 2017
Merged

test: have inspector test pick an open port #10861

merged 1 commit into from
Jan 19, 2017

Conversation

eugeneo
Copy link
Contributor

@eugeneo eugeneo commented Jan 18, 2017

This ensures that cctest can be ran concurrently with other instances of
cctest or while the node is ran with --inspect.

Ref: #10858

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines
Affected core subsystem(s)

test, inspector - server now works with the port 0 and test leverages that.

@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. dont-land-on-v4.x inspector Issues and PRs related to the V8 inspector protocol labels Jan 18, 2017
@mscdex mscdex added the test Issues and PRs related to the tests. label Jan 18, 2017
Copy link
Contributor

@cjihrig cjihrig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with a comment.

@@ -137,6 +137,21 @@ void SendProtocolJson(InspectorSocket* socket) {
SendHttpResponse(socket, data);
}

int GetPort(uv_tcp_t* socket, int* err) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it make more sense to return the error code and pass the port through a function argument (basically the reverse of the current situation)?

@eugeneo
Copy link
Contributor Author

eugeneo commented Jan 19, 2017

@cjihrig I did that, new version uploaded.

Copy link
Contributor

@cjihrig cjihrig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. LGTM if the CI comes back green.

@eugeneo
Copy link
Contributor Author

eugeneo commented Jan 19, 2017

For some reason, GitHub integration is showing failed tests while https://ci.nodejs.org/job/node-test-pull-request/5950/ is green.

@cjihrig
Copy link
Contributor

cjihrig commented Jan 19, 2017

Yea, that has been a problem for a while now. I think the build team has it on their radar.

This ensures that cctest can be ran concurrently with other instances of
cctest or while the node is ran with --inspect.

Ref: #10858
PR-URL: #10861
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
@eugeneo eugeneo merged commit 295bd11 into nodejs:master Jan 19, 2017
@eugeneo eugeneo deleted the concurrent-test branch January 19, 2017 19:58
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 25, 2017
This ensures that cctest can be ran concurrently with other instances of
cctest or while the node is ran with --inspect.

Ref: nodejs#10858
PR-URL: nodejs#10861
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
italoacasas pushed a commit to italoacasas/node that referenced this pull request Jan 27, 2017
This ensures that cctest can be ran concurrently with other instances of
cctest or while the node is ran with --inspect.

Ref: nodejs#10858
PR-URL: nodejs#10861
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
@italoacasas italoacasas mentioned this pull request Jan 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++. inspector Issues and PRs related to the V8 inspector protocol test Issues and PRs related to the tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants