-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjest.config.js
More file actions
30 lines (29 loc) · 808 Bytes
/
Copy pathjest.config.js
File metadata and controls
30 lines (29 loc) · 808 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
const path = require('path');
// const { pathsToModuleNameMapper } = require('ts-jest');
// const { compilerOptions } = require('./tsconfig.json');
module.exports = {
moduleFileExtensions: ['ts', 'js'],
transform: {
'^.+\\.(ts|js)?$': [
'ts-jest',
{
tsconfig: 'tsconfig.jest.json',
useESM: true,
},
],
},
testMatch: ['!**/lib/**', '**/__tests__/tests/**/*jest.(js|ts)'],
testPathIgnorePatterns: [
// TODO: need to fix cli tests
'<rootDir>/__tests__/tests/cli/init',
],
setupFilesAfterEnv: [
process.env.LEGACY ? './__tests__/setup_legacy.js' : './__tests__/setup.js',
],
testEnvironment: 'node',
moduleNameMapper: {
'^@tps/(.+)$': path.join(__dirname, 'src/$1'),
'^@test/(.+)$': path.join(__dirname, '__tests__/$1'),
'^templates-mo$': path.join(__dirname),
},
};