-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathjest.config.js
More file actions
34 lines (34 loc) · 920 Bytes
/
jest.config.js
File metadata and controls
34 lines (34 loc) · 920 Bytes
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
module.exports = {
testEnvironment: 'jsdom',
roots: ['<rootDir>/test', '<rootDir>/src'],
testMatch: ['**/*.spec.ts', '**/*.test.ts', '**/*.spec.tsx', '**/*.test.tsx'],
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
collectCoverageFrom: [
'src/**/*.{ts,tsx}',
'!src/**/*.d.ts',
'!src/index.ts',
'!src/types.ts',
],
coverageReporters: ['text', 'lcov', 'html'],
coverageDirectory: 'coverage',
transform: {
'^.+\\.tsx?$': 'babel-jest',
},
moduleNameMapper: {
'\\.(css|less|scss|sass)$': 'identity-obj-proxy',
},
setupFilesAfterEnv: ['<rootDir>/test/setup.ts'],
reporters: [
'default',
[
'jest-html-reporter',
{
pageTitle: 'Flutterwave React v3 Test Report',
outputPath: './test-report/index.html',
includeFailureMsg: true,
includeConsoleLog: false,
theme: 'darkTheme',
},
],
],
};