Skip to content

Commit

Permalink
feat: add moduleDirectories to jest config
Browse files Browse the repository at this point in the history
  • Loading branch information
kentcdodds committed Oct 5, 2020
1 parent 6ce5817 commit 4961e97
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/config/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ const jestConfig = {
),
testURL: 'http://localhost',
moduleFileExtensions: ['js', 'jsx', 'json', 'ts', 'tsx'],
moduleDirectories: [
'node_modules',
fromRoot('src'),
'shared',
fromRoot('tests'),
],
collectCoverageFrom: ['src/**/*.+(js|jsx|ts|tsx)'],
testMatch: ['**/__tests__/**/*.+(js|jsx|ts|tsx)'],
testPathIgnorePatterns: [...ignores],
Expand Down

0 comments on commit 4961e97

Please sign in to comment.