MCPcopy
hub / github.com/jestjs/jest / _ignore

Method _ignore

packages/jest-haste-map/src/index.ts:1095–1106  ·  view source on GitHub ↗

* Helpers

(filePath: string)

Source from the content-addressed store, hash-verified

1093 * Helpers
1094 */
1095 private _ignore(filePath: string): boolean {
1096 const ignorePattern = this._options.ignorePattern;
1097 const ignoreMatched =
1098 ignorePattern instanceof RegExp
1099 ? ignorePattern.test(filePath)
1100 : ignorePattern && ignorePattern(filePath);
1101
1102 return (
1103 ignoreMatched ||
1104 (!this._options.retainAllFiles && filePath.includes(NODE_MODULES))
1105 );
1106 }
1107
1108 private async _shouldUseWatchman(): Promise<boolean> {
1109 if (!this._options.useWatchman) {

Callers 1

onChangeMethod · 0.95

Calls 1

testMethod · 0.45

Tested by

no test coverage detected