Skip to content

test: Change equal to strictEqual and pass delay to setTimeout - #9938

Closed
qualquervalor2 wants to merge 3 commits into
nodejs:masterfrom
qualquervalor2:tweakDomainExitTest
Closed

test: Change equal to strictEqual and pass delay to setTimeout#9938
qualquervalor2 wants to merge 3 commits into
nodejs:masterfrom
qualquervalor2:tweakDomainExitTest

Conversation

@qualquervalor2

@qualquervalor2qualquervalor2 commented Dec 1, 2016

Copy link
Copy Markdown
Checklist
  • make -j8 test (UNIX), or vcbuild test nosign (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test

Description of change
  • Changed assert.equal to assert.strictEqual
  • Passed a delay value to setTimeout

@nodejs-github-botnodejs-github-bot added the test Issues and PRs related to the tests. label Dec 1, 2016
@mscdexmscdex added the domain Issues and PRs related to the domain subsystem. label Dec 1, 2016
@imyllerimyller added the code-and-learn Issues related to the Code-and-Learn events and PRs submitted during the events. label Dec 1, 2016
disposalFailed = true;
process.exit(1);
});
}, 0);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@qualquervalor2 Could you check if this works with setImmediate() instead of setTimeout()?

If it doesn't work, could you change the 0 to a 1? The 0 becomes a 1 under the hood so it would be better to be explicit up front. :)

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

setImediate() did not work. Updated the PR to use 1.

disposalFailed = true;
process.exit(1);
});
}, 1);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This can likely be changed to use common.mustCall() ... for instance:

setTimeout(common.mustCall(()=>{},0),1);

@mhdawsonmhdawson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

@mhdawson

Copy link
Copy Markdown
Member

@jasnell

Copy link
Copy Markdown
Member

@Fishrock123 ... are you good with this now?

Trott pushed a commit to Trott/io.js that referenced this pull request Dec 7, 2016
change equal to strictEqual, fix setTimeout
PR-URL: nodejs#9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
@Trott

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member

Landed in 25dfb8e

@TrottTrott closed this Dec 7, 2016
@Trott

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member

Thanks for the contribution! 🎉

addaleax pushed a commit that referenced this pull request Dec 8, 2016
change equal to strictEqual, fix setTimeout
PR-URL: #9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
addaleax pushed a commit to addaleax/node that referenced this pull request Dec 8, 2016
change equal to strictEqual, fix setTimeout
PR-URL: nodejs#9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
@italoacasasitaloacasas mentioned this pull request Dec 15, 2016
MylesBorins pushed a commit that referenced this pull request Dec 20, 2016
change equal to strictEqual, fix setTimeout
PR-URL: #9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 21, 2016
change equal to strictEqual, fix setTimeout
PR-URL: #9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 21, 2016
change equal to strictEqual, fix setTimeout
PR-URL: #9938
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
This was referenced Dec 21, 2016
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

code-and-learnIssues related to the Code-and-Learn events and PRs submitted during the events.domainIssues and PRs related to the domain subsystem.testIssues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

11 participants

@qualquervalor2@mhdawson@jasnell@Trott@Fishrock123@lpinca@mscdex@MylesBorins@addaleax@imyller@nodejs-github-bot