(test, patterns)
| 171 | } |
| 172 | |
| 173 | function testMatchesPattern(test, patterns) { |
| 174 | const matchesByNameOrParent = ArrayPrototypeSome(patterns, (re) => |
| 175 | RegExpPrototypeExec(re, test.name) !== null, |
| 176 | ) || (test.parent && testMatchesPattern(test.parent, patterns)); |
| 177 | if (matchesByNameOrParent) return true; |
| 178 | |
| 179 | const testNameWithAncestors = StringPrototypeTrim(test.getTestNameWithAncestors()); |
| 180 | |
| 181 | return ArrayPrototypeSome(patterns, (re) => |
| 182 | RegExpPrototypeExec(re, testNameWithAncestors) !== null, |
| 183 | ); |
| 184 | } |
| 185 | |
| 186 | class TestPlan { |
| 187 | #waitIndefinitely = false; |
no test coverage detected