-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
48 lines (48 loc) · 999 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
module.exports = {
preset: 'ts-jest',
testMatch: [
'**/?(*.)+(spec|test).[tj]s?(x)'
],
globals: {
'ts-jest': {
babelConfig: true,
diagnostics: {
warnOnly: true
}
}
},
snapshotSerializers: [
'jest-serializer-vue'
],
transformIgnorePatterns: [
'/node_modules/'
],
watchPlugins: [
'jest-watch-typeahead/filename',
'jest-watch-typeahead/testname'
],
// @todo Temporary fix for the https://github.com/facebook/jest/issues/6766
testURL: 'http://localhost',
testPathIgnorePatterns: [
'/.git/',
'<rootDir>/build/',
'<rootDir>/temp/',
'/node_modules/'
],
moduleFileExtensions: [
'js',
'jsx',
'json',
'vue',
'ts',
'tsx'
],
moduleNameMapper: {
'^@data$': '<rootDir>/temp/data/scripts.js'
},
transform: {
'^.+\\.tsx?$': '<rootDir>/node_modules/ts-jest',
'^.+\\.jsx?$': '<rootDir>/node_modules/babel-jest',
'.*\\.(vue)$': '<rootDir>/node_modules/vue-jest'
}
}