-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
32 lines (30 loc) · 973 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
const esModules = ['emoji-picker-element', '@webitel/ui-sdk/src', '@webitel/cc-ui-sdk/src', 'webitel-sdk'].join('|');
module.exports = {
preset: '@vue/cli-plugin-unit-jest',
transform: {
'^.+\\.jsx?$': '<rootDir>/node_modules/babel-jest',
},
transformIgnorePatterns: [`/node_modules/(?!${esModules})`],
reporters: ['default', 'bamboo-jest-reporter'],
moduleNameMapper: { '\\.(css|less)$': '<rootDir>/tests/unit/mock/fileMock.js' },
collectCoverage: true,
// coverageThreshold: {
// global: {
// branches: 80,
// functions: 80,
// statements: 80,
// lines: 80,
// },
// },
collectCoverageFrom: [
'src/**/*.{js,vue}',
'!src/**/index.js', // No need to cover bootstrap file
'!src/**/main.js', // No need to cover bootstrap file
],
setupFiles: [
// 'jest-canvas-mock',
'./tests/config/config.js',
// './src/plugins/index.js',
],
setupFilesAfterEnv: ['./tests/config/jest.config.js'],
};