You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

jest.config.js 652B

123456789101112131415161718192021
  1. module.exports = {
  2. roots: ['<rootDir>'],
  3. testEnvironment: 'jsdom',
  4. moduleFileExtensions: ['ts', 'tsx', 'mjs', 'js', 'json', 'jsx'],
  5. testPathIgnorePatterns: ['<rootDir>[/\\\\](node_modules|.next)[/\\\\]'],
  6. transformIgnorePatterns: [
  7. 'node_modules/(?!(browser-fs-access)/)',
  8. ],
  9. transform: {
  10. '^.+\\.(ts|tsx|mjs)$': 'babel-jest',
  11. },
  12. modulePaths: ['<rootDir>', 'node_modules'],
  13. watchPlugins: [
  14. 'jest-watch-typeahead/filename',
  15. 'jest-watch-typeahead/testname',
  16. ],
  17. moduleNameMapper: {
  18. '\\.(css|less|sass|scss)$': 'identity-obj-proxy',
  19. '\\.(gif|ttf|eot|svg|png)$': '<rootDir>/test/__mocks__/fileMock.js',
  20. },
  21. }