-
Notifications
You must be signed in to change notification settings - Fork 29.6k
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: swap arguments in strictEqual() for parallel/test-buffer-copy #23204
Conversation
test/parallel/test-buffer-copy.js
Outdated
@@ -23,7 +23,7 @@ let cntr = 0; | |||
b.fill(++cntr); | |||
c.fill(++cntr); | |||
const copied = c.copy(b, 0, 0); | |||
assert.strictEqual(c.length, copied); | |||
assert.strictEqual(copied, c.length); | |||
for (let i = 0; i < c.length; i++) { | |||
assert.strictEqual(c[i], b[i]); |
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.
I think these should be swapped as well (we copied c
into b
, so c
holds the expected values?)
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.
👍
test/parallel/test-buffer-copy.js
Outdated
@@ -34,7 +34,7 @@ let cntr = 0; | |||
b.fill(++cntr); | |||
c.fill(++cntr); | |||
const copied = c.copy(b, 0); | |||
assert.strictEqual(c.length, copied); | |||
assert.strictEqual(copied, c.length); | |||
for (let i = 0; i < c.length; i++) { | |||
assert.strictEqual(c[i], b[i]); |
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.
ditto
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.
👍
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.
Thank you!
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.
Thank you for doing this and welcome :)
Swap arguments in strictEqual() for parallel/test-buffer-copy. PR-URL: nodejs#23204 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Swap arguments in strictEqual() for parallel/test-buffer-copy. PR-URL: #23204 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Swap arguments in strictEqual() for parallel/test-buffer-copy. PR-URL: #23204 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Swap arguments in strictEqual() for parallel/test-buffer-copy. PR-URL: #23204 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes