2023-12-10 18:22:43 +03:00
|
|
|
export default {
|
|
|
|
setupFilesAfterEnv: ["./src/setupTests.ts"],
|
|
|
|
testEnvironment: "jsdom",
|
|
|
|
transform: {
|
|
|
|
"^.+\\.(ts|js|tsx|jsx)$": "@swc/jest",
|
|
|
|
},
|
|
|
|
moduleNameMapper: {
|
|
|
|
'~/(.+)': "<rootDir>/src/$1",
|
|
|
|
'@/(.+)': "<rootDir>/src/modules/$1",
|
|
|
|
'@testing/(.+)': "<rootDir>/src/testing/$1",
|
|
|
|
},
|
|
|
|
extensionsToTreatAsEsm: ['.ts', '.tsx'],
|
2023-12-14 22:08:03 +03:00
|
|
|
coverageThreshold: {
|
|
|
|
global: {
|
|
|
|
statements: 10,
|
|
|
|
lines: 10,
|
2023-12-15 12:53:20 +03:00
|
|
|
functions: 7,
|
2023-12-14 22:08:03 +03:00
|
|
|
},
|
|
|
|
},
|
|
|
|
collectCoverage: true,
|
|
|
|
collectCoverageFrom: ['<rootDir>/src/**/*.ts'],
|
|
|
|
coveragePathIgnorePatterns: [
|
|
|
|
'states/.+State.ts$',
|
|
|
|
'contexts/.+Context.ts',
|
|
|
|
'testing/*',
|
|
|
|
'tests/*',
|
|
|
|
'config/*',
|
|
|
|
'graphql/queries/*',
|
|
|
|
'graphql/mutations/*',
|
|
|
|
'graphql/fragments/*',
|
|
|
|
'types/*',
|
|
|
|
'constants/*',
|
|
|
|
'generated-metadata/*',
|
|
|
|
'generated/*',
|
|
|
|
'__stories__/*',
|
|
|
|
|
|
|
|
],
|
2023-12-10 18:22:43 +03:00
|
|
|
// coverageDirectory: '<rootDir>/coverage/',
|
|
|
|
}
|