Skip to content

Commit

Permalink
Remove the default for modulePathIgnorePatterns
Browse files Browse the repository at this point in the history
Reviewed By: DmitrySoshnikov

Differential Revision: D2577615

fb-gh-sync-id: 0811d6c5201d51f8095fca5eb8aedfa56b611015
  • Loading branch information
cpojer authored and facebook-github-bot-8 committed Oct 23, 2015
1 parent d96b251 commit abcd590
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion CHANGELOG.md
Expand Up @@ -4,7 +4,6 @@
* Use the current working directory as root when passing a jest config from
the command line.
* Updated the React examples and getting started guide
* Set `modulePathIgnorePatterns` to `node_modules` by default.
* Modules now receive a `module.parent` field so unmocked modules don't assume
they are run directly any longer.

Expand Down
2 changes: 1 addition & 1 deletion docs/API.md
Expand Up @@ -324,7 +324,7 @@ An array of file extensions your modules use. If you require modules without spe
If you are using CoffeeScript this should be `['js', 'json', 'coffee', 'litcoffee', 'coffee.md']`

### `config.modulePathIgnorePatterns` [array<string>]
(default: `["/node_modules/"]`)
(default: `[]`)

An array of regexp pattern strings that are matched against all module paths before those paths are to be considered 'visible' to the module loader. If a given module's path matches any of the patterns, it will not be `require()`-able in the test environment.

Expand Down
2 changes: 1 addition & 1 deletion src/lib/utils.js
Expand Up @@ -27,7 +27,7 @@ var DEFAULT_CONFIG_VALUES = {
moduleFileExtensions: ['js', 'json'],
moduleLoader: require.resolve('../HasteModuleLoader/HasteModuleLoader'),
preprocessorIgnorePatterns: [],
modulePathIgnorePatterns: ['/node_modules/'],
modulePathIgnorePatterns: [],
moduleNameMapper: [],
testDirectoryName: '__tests__',
testEnvironment: require.resolve('../JSDomEnvironment'),
Expand Down

0 comments on commit abcd590

Please sign in to comment.