-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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: test isFullWidthCodePoint with invalid input #7422
Conversation
There’s a typo ( |
Typo fixed, thanks! |
LGTM if CI is happy: https://ci.nodejs.org/job/node-test-pull-request/3084/ |
@@ -327,6 +327,9 @@ function isWarned(emitter) { | |||
rli.close(); | |||
} | |||
|
|||
// isFullWidthCodePoint() should return false for non-numeric values | |||
assert.strictEqual(internalReadline.isFullWidthCodePoint('あ'), false); |
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.
Perhaps you can extend this to [true, false, null, undefined, {}, [], 'あ'].forEach((v) => {
?
LGTM with a suggestion. |
LGTM with @bnoordhuis' suggestion |
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input.
Added the additional primitives to check per @bnoordhuis. New CI: https://ci.nodejs.org/job/node-test-pull-request/3101/ |
One Raspberry Pi build on CI didn't complete, but otherwise, CI looks good. |
LGTM |
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: nodejs#7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Landed in bbf3838 |
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
appears to be using api's not in v4. Please correct me if wrong |
|
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Code coverage information shows that we are only testing the happy path for the internal readline `isFullWidthCodePoint()` function. Test it with invalid input. PR-URL: #7422 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
Checklist
make -j4 test
(UNIX) orvcbuild test nosign
(Windows) passesAffected core subsystem(s)
test readline
Description of change
Code coverage information shows that we are only testing the happy path
for the internal readlind
isFullWidthCodePoint()
function. Test itwith invalid input.