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: add mustCall() to test-inspector-contexts #30649

Merged
merged 4 commits into from Nov 28, 2019
Merged

Conversation

@Trott
Copy link
Member

Trott commented Nov 26, 2019

In test-inspector-contexts, if mainContextPromise is modified such that
the method argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
common.mustCall() to cause the test to fail if the second part of the
test does not run.

Refs: #30519 (comment)

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 26, 2019

Added a second commit to check for errors in session.post() by adding a callback.

@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 26, 2019

Added a third commit to remove destructuring that was making the test harder to read/understand, at least for me.

Added a fourth commit to add logging for a possible/probable infinite loop (or infinite-ish loop) that may be why the test times out sometimes on CI.

@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

Copy link

nodejs-github-bot commented Nov 26, 2019

@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 26, 2019

@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 27, 2019

test/sequential/test-inspector-contexts.js Outdated Show resolved Hide resolved
@Trott Trott force-pushed the Trott:contexts branch from c96727e to b759c58 Nov 27, 2019
@nodejs-github-bot

This comment was marked as outdated.

@Trott Trott added the author ready label Nov 27, 2019
@Trott Trott force-pushed the Trott:contexts branch from b759c58 to 491a858 Nov 27, 2019
@nodejs-github-bot

This comment was marked as outdated.

@lpinca
lpinca approved these changes Nov 27, 2019
@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

This comment has been minimized.

@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 27, 2019

Welp, this at least has the desired effect of supplying more information about why test-inspector-contexts sometimes hangs in CI.

13:29:09 not ok 1312 sequential/test-inspector-contexts
13:29:09   ---
13:29:09   duration_ms: 149.140
13:29:09   severity: fail
13:29:09   exitcode: 1
13:29:09   stack: |-
13:29:09     timeout
13:29:09     Testing context created/destroyed notifications
13:29:09     Checking/waiting for GC.
13:29:09   ...

So it looks like it just runs the first global.gc() over and over and the context is never garbage collected/destroyed?

@nodejs-github-bot

This comment was marked as outdated.

Trott added 3 commits Nov 26, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
@Trott Trott force-pushed the Trott:contexts branch from 491a858 to 15146e6 Nov 28, 2019
@Trott

This comment has been minimized.

Copy link
Member Author

Trott commented Nov 28, 2019

Landed in ea7a6f9...15146e6

@Trott Trott merged commit 15146e6 into nodejs:master Nov 28, 2019
1 check failed
1 check failed
Travis CI - Branch Build Created
Details
@Trott Trott deleted the Trott:contexts branch Nov 28, 2019
addaleax added a commit that referenced this pull request Nov 30, 2019
In test-inspector-contexts, if mainContextPromise is modified such that
the `method` argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
`common.mustCall()` to cause the test to fail if the second part of the
test does not run.

Refs: #30519 (comment)

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
addaleax added a commit that referenced this pull request Nov 30, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
addaleax added a commit that referenced this pull request Nov 30, 2019
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
addaleax added a commit that referenced this pull request Nov 30, 2019
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
targos added a commit that referenced this pull request Dec 1, 2019
In test-inspector-contexts, if mainContextPromise is modified such that
the `method` argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
`common.mustCall()` to cause the test to fail if the second part of the
test does not run.

Refs: #30519 (comment)

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
targos added a commit that referenced this pull request Dec 1, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
targos added a commit that referenced this pull request Dec 1, 2019
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
targos added a commit that referenced this pull request Dec 1, 2019
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
bmeck added a commit to bmeck/node that referenced this pull request Dec 2, 2019
In test-inspector-contexts, if mainContextPromise is modified such that
the `method` argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
`common.mustCall()` to cause the test to fail if the second part of the
test does not run.

Refs: nodejs#30519 (comment)

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
bmeck added a commit to bmeck/node that referenced this pull request Dec 2, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
bmeck added a commit to bmeck/node that referenced this pull request Dec 2, 2019
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
bmeck added a commit to bmeck/node that referenced this pull request Dec 2, 2019
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
@BridgeAR BridgeAR mentioned this pull request Dec 3, 2019
@BethGriggs BethGriggs mentioned this pull request Dec 9, 2019
Sebastien-Ahkrin added a commit to Sebastien-Ahkrin/node that referenced this pull request Dec 11, 2019
In test-inspector-contexts, if mainContextPromise is modified such that
the `method` argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
`common.mustCall()` to cause the test to fail if the second part of the
test does not run.

Refs: nodejs#30519 (comment)

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Sebastien-Ahkrin added a commit to Sebastien-Ahkrin/node that referenced this pull request Dec 11, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Sebastien-Ahkrin added a commit to Sebastien-Ahkrin/node that referenced this pull request Dec 11, 2019
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Sebastien-Ahkrin added a commit to Sebastien-Ahkrin/node that referenced this pull request Dec 11, 2019
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: nodejs#30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
In test-inspector-contexts, if mainContextPromise is modified such that
the `method` argument is changed to something invalid, the test still
passes and the second part of the test never runs. Use
`common.mustCall()` to cause the test to fail if the second part of the
test does not run.

Refs: #30519 (comment)

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
If session.post() generates an error, it is currently ignored. Add check
for error by adding a callback to session.post() invocation.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
As I'm working with this test, I'm finding the destructuring of assert
and vm to make this test harder to read/understand. So I'm taking the
liberty of removing them.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
MylesBorins added a commit that referenced this pull request Dec 17, 2019
test-inspector-contexts may be entering an infinite loop (or very
long-running loop) in CI, resulting in flakiness. Or maybe not. Add
logging to find out.

PR-URL: #30649
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
@BethGriggs BethGriggs mentioned this pull request Dec 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.