Skip to content

Commit f96f9aa

Browse files
committed
fix(reactant): fix template testing config file and current testing config
1 parent abdf4b9 commit f96f9aa

File tree

5 files changed

+10
-4
lines changed

5 files changed

+10
-4
lines changed

packages/reactant-template/templates/web/typescript/template.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
{
22
"scripts": {
33
"start": "webpack-dev-server",
4-
"build": "webpack"
4+
"build": "webpack",
5+
"test": "jest --config jest.json"
56
},
67
"devDependencies": {
78
"@types/jest": "^24.0.25",
@@ -11,6 +12,8 @@
1112
"@types/react-redux": "^7.1.7",
1213
"@types/react-router-dom": "^5.1.3",
1314
"copy-webpack-plugin": "^5.1.1",
15+
"jest": "^24.9.0",
16+
"ts-jest": "^24.2.0",
1417
"ts-loader": "^6.2.1",
1518
"typescript": "^3.8.3",
1619
"webpack": "^4.43.0",
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"preset": "ts-jest"
3+
}

scripts/jest/dev.config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
"globals": {
55
"__DEV__": true
66
},
7-
"testPathIgnorePatterns": ["examples"]
7+
"testPathIgnorePatterns": ["examples", "packages/reactant-cli/templates"]
88
}

scripts/jest/prod.config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
"globals": {
55
"__DEV__": false
66
},
7-
"testPathIgnorePatterns": ["examples"]
7+
"testPathIgnorePatterns": ["examples", "packages/reactant-cli/templates"]
88
}

scripts/jest/useDefineForClassFields.config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@
99
}
1010
}
1111
},
12-
"testPathIgnorePatterns": ["examples"]
12+
"testPathIgnorePatterns": ["examples", "packages/reactant-cli/templates"]
1313
}

0 commit comments

Comments
 (0)