-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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: fix assert.strictEqual() parameter order #23564
Conversation
…eters follow the order actual-value->expected-value. Refs: test/parallel/test-tcp-wrap-connect.js
Hi @lotharthesavior – just as a heads up, our CI does not deal well with merge commits. Do you think you could rebase this instead? Let us know if you need any help! |
53a5add
to
91bd5fb
Compare
Hi, @addaleax , thanks for the review, I removed the merge commit. Let me know if there is something else. |
@lotharthesavior Thanks! |
|
||
const shutdownReq = new ShutdownWrap(); | ||
const err = client.shutdown(shutdownReq); | ||
assert.strictEqual(err, 0); | ||
|
||
shutdownReq.oncomplete = function(status, client_, error) { | ||
assert.strictEqual(0, status); | ||
assert.strictEqual(client, client_); | ||
assert.strictEqual(error, undefined); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this order be preserved?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, @trivikr , would you explain further you comment? I believe that the order here is already changed, unless you meant something else. I didn't understand before, but now I got what you said. I have a question, though: why would it be preserved?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My bad, the comment was for line 34.
The strictEqual assertions should follow the order actual-value
-> expected-value
, where error
is actual value, while undefined
is expected value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed while landing.
PR-URL: nodejs#23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
PR-URL: nodejs#23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
Landed in aee771c 🎉 @lotharthesavior congratulations on your commit to Node.js! |
Thanks, @BridgeAR ! I'm looking forward to contributing more! |
PR-URL: #23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
PR-URL: #23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
PR-URL: #23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
PR-URL: #23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
PR-URL: #23564 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
…follow the order actual-value->expected-value.
According to the documentation, the strictEqual assertions should follow the order
actual-value
->expected-value
. This PR is changing the current situation of the testparallel/test-tcp-wrap-connect.js
to accomplish it.Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes