forked from algenty/grafana-flowcharting
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
28 lines (28 loc) · 1009 Bytes
/
jest.config.js
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
module.exports = {
verbose: true,
globals: {
'ts-jest': {
tsConfig: 'tsconfig.jest.json',
},
},
roots: ['./spec'],
moduleDirectories: ['node_modules', 'public', 'src'],
modulePaths: ['./node_modules', './public', './src'],
// globalSetup: '<rootDir>/spec/globalSetup.js',
// globalTeardown: '<rootDir>/spec/globalTeardown.js',
setupFiles: ['<rootDir>/spec/setup-jest.js'],
transform: {
'^.+\\.jsx?$': 'babel-jest',
'^.+\\.tsx?$': 'ts-jest',
},
moduleNameMapper: {
underscore$: 'lodash',
'grafana/app/core/utils/kbn': '<rootDir>/spec/__mocks__/kbn.ts',
'grafana/app/plugins/sdk': '<rootDir>/spec/__mocks__/sdk.ts',
'grafana/app/core/time_series2': '<rootDir>/spec/__mocks__/time_series2.ts',
},
// transformIgnorePatterns: ['./public/.*', './node_modules/.*', './dist/.*'],
testRegex: '(\\.|/)(test)\\.(jsx?|tsx?)$',
transformIgnorePatterns: ['/node_modules/(?!vue-awesome)'],
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json'],
};