Skip to content

Commit

Permalink
Merge pull request #1419 from Arnei/vitest
Browse files Browse the repository at this point in the history
Complete replacing jest with vitest
  • Loading branch information
lkiesow authored Oct 17, 2024
2 parents b4427dc + e6347f1 commit 667eaef
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 232 deletions.
224 changes: 0 additions & 224 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
"@mui/material": "^5.16.7",
"@opencast/appkit": "^0.3.1",
"@reduxjs/toolkit": "^2.2.7",
"@testing-library/jest-dom": "^6.5.0",
"@types/react": "^18.3.11",
"@types/react-dom": "^18.3.0",
"deepmerge": "^4.3.1",
Expand Down
5 changes: 0 additions & 5 deletions src/setupTests.ts

This file was deleted.

2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"noEmit": true,
"jsx": "react-jsx",
"jsxImportSource": "@emotion/react",
"types": ["vite/client", "vite-plugin-svgr/client"]
"types": ["vite/client", "vite-plugin-svgr/client", "vitest/globals"]
},
"include": [
"src"
Expand Down
7 changes: 6 additions & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import react from "@vitejs/plugin-react";
import svgr from "vite-plugin-svgr";
import eslint from "vite-plugin-eslint";
import child from "child_process";
import { configDefaults } from 'vitest/config'

const commitHash = child.execSync("git rev-parse HEAD").toString().trim();

Expand Down Expand Up @@ -35,7 +36,11 @@ export default defineConfig(() => {
},
test: {
globals: true,
environment: "jsdom",
environment: 'jsdom',
exclude: [
...configDefaults.exclude,
'./tests',
],
},
};
});

0 comments on commit 667eaef

Please sign in to comment.