-
-
Notifications
You must be signed in to change notification settings - Fork 35.7k
Remove indexOf usage from tests in favor of includesΒ #12586
Copy link
Copy link
Closed
Labels
discussIssues opened for discussions and feedbacks.Issues opened for discussions and feedbacks.ltsIssues and PRs related to Long Term Support releases.Issues and PRs related to Long Term Support releases.testIssues and PRs related to the tests.Issues and PRs related to the tests.
Metadata
Metadata
Assignees
Labels
discussIssues opened for discussions and feedbacks.Issues opened for discussions and feedbacks.ltsIssues and PRs related to Long Term Support releases.Issues and PRs related to Long Term Support releases.testIssues and PRs related to the tests.Issues and PRs related to the tests.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Since v4 entered maintenance, do you think we can eliminate most of the 433 instances of
indexOffrom/test/*.js?Note: The prefered alternative is
assert.strictEqual(foo.includes(bar), true)Each hit should be evaluated whether it's an
includessurrogate, or a realindexOfuse:test\addons\repl-domain-abort
test\async-hooks
test\common
test\disabled
test\doctool
test\internet
test\parallel
test\pummel
and a special treat