-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
32 lines (32 loc) · 930 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
module.exports = {
globalSetup: '<rootDir>/jest-config/jest.setup.js',
moduleNameMapper: {
'^@/(.*)$': '<rootDir>/$1',
'^~/(.*)$': '<rootDir>/$1',
'^vue$': 'vue/dist/vue.common.js',
},
moduleFileExtensions: ['js', 'jsx', 'json', 'vue', 'ts', 'tsx'],
testEnvironment: 'jsdom',
transform: {
'.*\\.(vue)$': 'vue-jest',
'.*\\.(js)$': 'babel-jest',
},
setupFiles: ['<rootDir>/jest-config/jest.components.js'],
transformIgnorePatterns: [
'<rootDir>/node_modules/nuxt-lazy-load',
'<rootDir>/node_modules/@babel',
'<rootDir>/node_modules/@jest',
'signal-exit',
],
modulePathIgnorePatterns: [
'<rootDir>/.nuxt',
'<rootDir>/coverage',
'<rootDir>/node_modules',
'<rootDir>/.eslintrc.js',
'<rootDir>/nuxt.config.js',
'<rootDir>/jest.config.js',
'<rootDir>/jest-config',
],
collectCoverage: false,
collectCoverageFrom: ['<rootDir>/**/*.{js,vue}'],
};