jest.config.js 905 B

12345678910111213141516171819202122232425262728
  1. // jest.config.js
  2. const { defaults: tsjPreset } = require('ts-jest/presets')
  3. module.exports = {
  4. preset: 'react-native',
  5. globals: {
  6. 'ts-jest': {
  7. tsconfig: 'tsconfig.spec.json',
  8. },
  9. },
  10. transform: {
  11. '^.+\\.jsx$': 'babel-jest',
  12. '^.+\\.tsx?$': 'ts-jest',
  13. },
  14. moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
  15. "transformIgnorePatterns": [
  16. "node_modules/(?!(jest-)?react-native|react-clone-referenced-element|@react-native-community|expo(nent)?|@expo(nent)?/.*|react-navigation|@react-navigation/.*|@unimodules/.*|unimodules|sentry-expo|native-base|@sentry/.*|@react-native-community/picker)/"
  17. ],
  18. // collectCoverage: true,
  19. // collectCoverageFrom: [
  20. // "**/*.{js,jsx,ts,tsx}",
  21. // "!**/coverage/**",
  22. // "!**/node_modules/**",
  23. // "!**/docs/**",
  24. // "!**/babel.config.js",
  25. // "!**/jest.setup.js"
  26. // ],
  27. }