-
Notifications
You must be signed in to change notification settings - Fork 30k
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: fixed error message in test-buffer-read module #23957
test: fixed error message in test-buffer-read module #23957
Conversation
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.
Looks good to me if CI passes.
test/parallel/test-buffer-read.js
Outdated
RangeError); | ||
assert.throws( | ||
() => Buffer.allocUnsafe(8).readFloatBE(0xffffffff), | ||
{ |
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.
The following object can be stored in a variable and can be passed as a second argument:
{
name: 'RangeError [ERR_OUT_OF_RANGE]'
}
Same applies to this object on line 89 and 96:
{
name: 'RangeError [ERR_BUFFER_OUT_OF_BOUNDS]',
message: 'Attempt to write outside buffer bounds'
}
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.
Thanks @trivikr I will do the changes and commit.
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 see I missed the point. I had to parametrize the object, not the value. Pushing the changes in next commit.
Most of the tests passed. It failed for windows. Any known issue or something I should worry about why this is failing? |
Certainly unrelated. I've opened #24005 about it. Resume Build CI: https://ci.nodejs.org/job/node-test-pull-request/18266/ |
PR-URL: nodejs#23957 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Landed in e35f671. Thanks for the contribution! 🎉 (If you're interested in other possible contributions to Node.js but don't have a good idea of where to start looking, some ideas are posted at https://www.nodetodo.org/next-steps/.) |
PR-URL: #23957 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes