forked from sleeyax/secret-agent
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
37 lines (35 loc) · 989 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
const pkg = require('./package.json');
const workspaces = pkg.workspaces.packages
.filter(x => !x.startsWith('replay') && x !== 'website')
.map(x => x.replace('/*', ''));
module.exports = {
verbose: false,
testMatch: ['**/test/*.test.js'],
testEnvironment: 'node',
collectCoverage: false,
collectCoverageFrom: workspaces.map(x => `${x}/**/*.js`),
coveragePathIgnorePatterns: [
'node_modules',
'<rootDir>/.*/start.[ts|js]',
'<rootDir>/.*/install.[ts|js]',
'<rootDir>/.*/server.[ts|js]',
'<rootDir>/core-server/examples',
'<rootDir>/.*/test/.*.js',
'<rootDir>/.*.d.ts',
'<rootDir>/.*.json',
],
globalTeardown: './jest.teardown.js',
globalSetup: './jest.setup.js',
testTimeout: 10e3,
reporters: [
'default',
[
'jest-summary-reporter',
{
failuresOnly: true,
},
],
],
roots: workspaces.map(x => `${x}/`),
moduleDirectories: ['node_modules', ...workspaces.map(x => `${x}/node_modules`)],
};