Skip to content

Commit c1a38f7

Browse files
committed
some configs polishment
1 parent f322eb9 commit c1a38f7

File tree

4 files changed

+20
-16
lines changed

4 files changed

+20
-16
lines changed

jest.base-ts.config.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
const base = require('./jest.base.config');
2+
3+
/** @type {import('jest').Config} */
4+
module.exports = {
5+
...base,
6+
preset: 'ts-jest',
7+
testMatch: ['<rootDir>/test/**/*.test.ts'],
8+
moduleFileExtensions: ['ts', 'js', 'json'],
9+
transform: {
10+
'^.+\\.ts$': 'ts-jest',
11+
},
12+
collectCoverageFrom: [
13+
'<rootDir>/src/**/*.{ts,tsx}',
14+
'!<rootDir>/src/**/*.d.ts',
15+
]
16+
};
Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,11 @@
1-
const base = require('../../jest.base.config');
1+
const base = require('../../jest.base-ts.config');
22

33
/** @type {import('jest').Config} */
44
module.exports = {
55
...base,
6-
preset: 'ts-jest',
76
rootDir: '.',
8-
testMatch: ['<rootDir>/test/**/*.test.ts'],
9-
moduleFileExtensions: ['ts', 'js', 'json'],
10-
transform: {
11-
'^.+\\.ts$': ['ts-jest', { tsconfig: 'tsconfig.jest.json' }],
12-
},
137
collectCoverageFrom: [
14-
'<rootDir>/src/**/*.{ts,tsx}',
15-
'!<rootDir>/src/**/*.d.ts',
8+
...base.collectCoverageFrom,
9+
'!<rootDir>/src/index.umd.ts',
1610
],
1711
};

packages/cubejs-client-core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"@types/ramda": "^0.27.34",
4545
"babel-jest": "^29",
4646
"jest": "^29",
47-
"ts-jest": "^29.3.3",
47+
"ts-jest": "^29",
4848
"typescript": "~5.2.2"
4949
},
5050
"eslintConfig": {

packages/cubejs-client-core/tsconfig.jest.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

0 commit comments

Comments
 (0)