-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathjest.config.js
33 lines (30 loc) · 1.09 KB
/
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
const { jestConfig } = require("@salesforce/sfdx-lwc-jest/config");
const setupFilesAfterEnv = jestConfig.setupFilesAfterEnv || [];
setupFilesAfterEnv.push("<rootDir>/jest.setup.js");
// Repo needs to have have 100% LWC Jest test code coverage across all measures.
const coverageThreshold = jestConfig.coverageThreshold || {};
/*
coverageThreshold.global = {
branches: 100,
functions: 100,
lines: 100,
statements: 0,
};
*/
// TODO: All LWC Jest tests require 100% code coverage that are not in the block list specified by this glob. Remove components from the block list specified in this glob when code coverage is met.
coverageThreshold[
"./force-app/main/default/lwc/!(gauExpenditureRow|lookup|manageExpenditures|manageExpendituresTableHeader)/**"
] = {
branches: 100,
functions: 100,
lines: 100,
statements: 0,
};
module.exports = {
...jestConfig,
moduleNameMapper: {},
testPathIgnorePatterns: ["force-app/main/default/lwc/__(tests|mocks)__/"],
reporters: ["default"],
setupFilesAfterEnv: setupFilesAfterEnv,
coverageThreshold: coverageThreshold,
};