mirror of https://github.com/djteang/OrangeTV.git
26 lines
803 B
JavaScript
26 lines
803 B
JavaScript
module.exports = {
|
|
setupFilesAfterEnv: ['<rootDir>/jest.setup.js'],
|
|
moduleDirectories: ['node_modules', '<rootDir>/'],
|
|
testEnvironment: 'jest-environment-jsdom',
|
|
transform: {
|
|
'^.+\\.(ts|tsx)$': [
|
|
'babel-jest',
|
|
{
|
|
presets: [
|
|
['@babel/preset-env', { targets: { node: 'current' } }],
|
|
['@babel/preset-react', { runtime: 'automatic' }],
|
|
'@babel/preset-typescript',
|
|
],
|
|
},
|
|
],
|
|
},
|
|
testPathIgnorePatterns: ['<rootDir>/node_modules/', '<rootDir>/dist/'],
|
|
modulePathIgnorePatterns: ['<rootDir>/dist/'],
|
|
moduleNameMapper: {
|
|
'^@heroui/react$': '<rootDir>/src/__mocks__/heroui-react.tsx',
|
|
'^@/(.*)$': '<rootDir>/src/$1',
|
|
'^~/(.*)$': '<rootDir>/public/$1',
|
|
'^.+\\.(svg)$': '<rootDir>/src/__mocks__/svg.tsx',
|
|
},
|
|
};
|