-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathjest.config.ts
35 lines (31 loc) · 1012 Bytes
/
jest.config.ts
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
/*
* SPDX-FileCopyrightText: 2022 Zextras <https://www.zextras.com>
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { Config } from 'jest';
import { defaultConfig } from './src/carbonio-ui-commons/test/jest-config';
/*
* For a detailed explanation regarding each configuration property and type check, visit:
* https://jestjs.io/docs/configuration
*/
const config: Config = {
...defaultConfig,
collectCoverageFrom: [
'src/**/*.{js,ts}(x)?',
'!**/__mocks__/**', // Exclude mock files
'!**/__tests__/**', // Exclude test files
'!**/*.test.{js,jsx,ts,tsx}', // Exclude test files
'!**/*.spec.{js,jsx,ts,tsx}', // Exclude test files
'!src/tests/**', // Exclude test files from src/tests
'!src/**/test/mocks/**' // Exclude test files from src/**/test/mocks
],
moduleNameMapper: {
...defaultConfig.moduleNameMapper,
'\\.(css|less)$': '<rootDir>/__mocks__/fileMock.js'
},
collectCoverage: true,
coverageReporters: ['lcov', 'html'],
testTimeout: 20000
};
export default config;