-
Notifications
You must be signed in to change notification settings - Fork 0
/
wallaby.js
35 lines (34 loc) · 905 Bytes
/
wallaby.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
//
// Wallaby config reads tsconfig.json and jest.config.js out of the box
//
module.exports = function(wallaby) {
return {
files: [
'src/**/*.ts?(x)',
'src/**/*.js?(x)',
'src/**/*.json',
'!src/**/*.test.ts?(x)',
'tools/**/*.js',
'package.json',
'tsconfig.json',
'jest.config.js',
],
tests: ['src/**/*.test.ts?(x)'],
env: { type: 'node', runner: 'node' },
testFramework: 'jest',
// like ts-jest need to hoist jest.mock() so use babel after ts to js
// https://github.com/wallabyjs/public/issues/1375
preprocessors: {
'**/*.js?(x)': file =>
require('babel-core').transform(file.content, {
sourceMap: true,
filename: file.path,
compact: false,
babelrc: true,
}),
},
debug: true,
reportConsoleErrorAsError: true,
lowCoverageThreshold: 80,
};
};