-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvitest.config.ts
More file actions
43 lines (42 loc) · 1.16 KB
/
vitest.config.ts
File metadata and controls
43 lines (42 loc) · 1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import path from "node:path";
import react from "@vitejs/plugin-react-swc";
import { defineConfig } from "vitest/config";
export default defineConfig({
plugins: [react({ tsDecorators: true })],
test: {
environment: "jsdom",
globals: true,
setupFiles: ["./tests/setup.ts"],
include: ["tests/**/*.test.{ts,tsx}"],
coverage: {
provider: "v8",
reporter: ["text", "text-summary", "html"],
include: [
"src/lib/**",
"src/stores/**",
"src/components/**",
"src/hooks/**",
],
exclude: [
"src/components/ui/**", // shadcn primitives — not unit tested
"src/data/**", // static game data / constants
"src/presets/**", // bundled preset JSONs
"src/lib/team-comp/impl/**", // per-character/weapon data definitions
"src/lib/team-comp/registry.ts", // registration boilerplate
"src/lib/tourConfig.ts", // UI tour definitions
"**/*.d.ts",
],
thresholds: {
lines: 58,
functions: 52,
branches: 43,
statements: 58,
},
},
},
resolve: {
alias: {
"@": path.resolve(__dirname, "./src"),
},
},
});