mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
test_runner: remove no-op validation
The code already checks if testNamePatterns is an array, and converts it to an array if it is not. PR-URL: https://github.com/nodejs/node/pull/47687 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Moshe Atlow <moshe@atlow.co.il> Reviewed-By: Debadree Chatterjee <debadree333@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
This commit is contained in:
1 parent
84fa9fd725
commit
f8581e7629
1 file changed
+1
-1
@@ -391,7 +391,7 @@ function run(options) {
|
||||
if (!ArrayIsArray(testNamePatterns)) {
|
||||
testNamePatterns = [testNamePatterns];
|
||||
}
|
||||
validateArray(testNamePatterns, 'options.testNamePatterns');
|
||||
|
||||
testNamePatterns = ArrayPrototypeMap(testNamePatterns, (value, i) => {
|
||||
if (isRegExp(value)) {
|
||||
return value;
|
||||
|
||||
Reference in new issue
Block a user