Skip to content

Commit

Permalink
feat(vite): enable running jest tests with vite
Browse files Browse the repository at this point in the history
  • Loading branch information
luqven committed May 9, 2023
1 parent 9dbf828 commit c6cd5ec
Show file tree
Hide file tree
Showing 3 changed files with 2,046 additions and 42 deletions.
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"clean": "rm -rf dist",
"serve": "vite preview",
"test": "run-s test:unit test:e2e",
"test:unit": "vite test:unit",
"test:unit": "jest",
"test:e2e": "concurrently --n \"vite,cypress\" --p \"[{name}]\" -c \"green,yellow\" \"yarn dev\" \"npx cypress run --browser chrome\" -k",
"lint": "eslint --ext .js,.vue --ignore-path .gitignore --fix src",
"lint:ci": "eslint --no-fix --max-warnings 0",
Expand All @@ -56,9 +56,12 @@
"@testing-library/jest-dom": "5.16.5",
"@testing-library/vue": "6.6.1",
"@types/jest": "24.9.1",
"@types/node": "^18.16.1",
"@typescript-eslint/eslint-plugin": "5.20.0",
"@typescript-eslint/parser": "5.20.0",
"@vitejs/plugin-vue": "^1.6.1",
"@vue/cli-plugin-babel": "^5.0.8",
"@vue/cli-plugin-unit-jest": "^5.0.8",
"@vue/compiler-sfc": "3.2.47",
"@vue/eslint-config-prettier": "6.0.0",
"@vue/eslint-config-typescript": "10.0.0",
Expand Down
3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"baseUrl": ".",
"types": [
"webpack-env",
"jest"
"jest",
"node"
],
"paths": {
"@/*": [
Expand Down
Loading

0 comments on commit c6cd5ec

Please sign in to comment.