Skip to content

Commit 987fd2d

Browse files
committed
test: swap from ts-jest and babel-jest for @swc/jest
1 parent cf4d763 commit 987fd2d

File tree

5 files changed

+7080
-9131
lines changed

5 files changed

+7080
-9131
lines changed

babel.config.js

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

jest.config.js

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,21 @@ module.exports = {
5050
roots: ['<rootDir>/tests'],
5151
testMatch: ['**/?(*.)+(spec|test|unit.test).+(ts|tsx|js|jsx)'],
5252
transform: {
53-
'^.+\\.tsx?$': 'ts-jest',
54-
'^.+\\.jsx?$': 'babel-jest',
53+
"^.+\\.(t|j)sx?$": [
54+
"@swc/jest",
55+
{
56+
"jsc": {
57+
"parser": {
58+
"syntax": "typescript",
59+
"dynamicImport": true,
60+
"tsx": true,
61+
"decorators": compilerOptions.experimentalDecorators,
62+
},
63+
"target": compilerOptions.target.toLowerCase(),
64+
"keepClassNames": true,
65+
},
66+
}
67+
],
5568
},
5669
reporters: [
5770
'default',

0 commit comments

Comments
 (0)