Skip to content

Commit

Permalink
feat(config/jest): @swc/jest@swc-node/jest (supports tsconfig)
Browse files Browse the repository at this point in the history
  • Loading branch information
jrolfs committed Sep 29, 2022
1 parent c81409e commit 7627f06
Show file tree
Hide file tree
Showing 3 changed files with 204 additions and 106 deletions.
6 changes: 3 additions & 3 deletions package.json
Expand Up @@ -26,7 +26,7 @@
"start": "run-p start:*",
"start:source": "yarn build:source --watch",
"start:types": "tsc -b -w --preserveWatchOutput src/",
"test": "node src test",
"test": "SWC_NODE_PROJECT=src/tsconfig.json node src test",
"test:update": "node src test --updateSnapshot",
"validate": "node src validate",
"prepare": "husky install"
Expand All @@ -53,8 +53,8 @@
"@commitlint/cli": "^16.1.0",
"@commitlint/config-conventional": "^16.2.1",
"@commitlint/prompt": "^16.1.0",
"@swc/core": "^1.2.248",
"@swc/jest": "^0.2.22",
"@swc-node/jest": "^1.5.2",
"@swc/core": "^1.3.3",
"@types/jest": "^29.0.0",
"@types/lodash.has": "^4.5.6",
"@types/mkdirp": "^1.0.2",
Expand Down
2 changes: 1 addition & 1 deletion src/config/jest.config.js
Expand Up @@ -44,7 +44,7 @@ const jestConfig = {
],
),
)
: {'^.+\\.(t|j)sx?$': ['@swc/jest']},
: {'^.+\\.(t|j)sx?$': ['@swc-node/jest']},
coveragePathIgnorePatterns: [
...ignores,
'src/(umd|cjs|esm)-entry.js$',
Expand Down

0 comments on commit 7627f06

Please sign in to comment.