Add support for recursiveDenylist
option as an alternative to recursiveBlacklist
#10649
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Clone of #10236 which has to be closed because the original repo was deleted by me.
Part of #10235.
recursiveDenylist
option as an alternative torecursiveBlacklist
injest-validate
. Does NOT removerecursiveBlacklist
option. It will continue to work, unless overwritten withrecursiveDenylist
, to which I've given the priority.recursiveBlacklist
(in favor of the newly added option).Changes internal calls tovalidate()
to use new config (Maintainers: I'm not sure if that's a good idea - can you please advise? Should we expectjest-config
, say, v26.2 work with other dependencies @ v26.1 at all times? Shall I roll that back and add it as a TODO to Replace non-inclusive terms used in configuration of jest-validate #10235 instead? TIA)Motivation
Part of continuous effort to get rid of non-inclusive terms like "whitelist" and "blacklist" implying that white = good and black = bad.
Test plan
jest-validate
had one suite whererecursiveBlacklist
option was used, in two cases:recursiveBlacklist
optionThe former was left intact, and copied 1:1 over to create a new test, testing whether
recursiveDenylist
beaves exactly the same asrecursiveBlacklist
.The latter was updated to use
recursiveDenylist
.Tests were ran successfully.