-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathvitest.config.ts
More file actions
28 lines (27 loc) · 932 Bytes
/
Copy pathvitest.config.ts
File metadata and controls
28 lines (27 loc) · 932 Bytes
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
import { defineConfig } from "vitest/config";
export default defineConfig({
test: {
globals: false,
environment: "node",
include: ["tests/**/*.test.ts"],
// Dist tests import from the published `nationid` package (via the
// `exports` map), which only resolves after `pnpm build`. They have
// their own runner via `vitest.dist.config.ts` invoked by `pnpm
// test:dist` AFTER the build step in `pnpm verify`. Excluding here
// prevents double-execution and the package-not-resolvable error
// under vitest 4 / Vite 7's stricter resolver.
exclude: ["**/node_modules/**", "tests/dist/**"],
coverage: {
provider: "v8",
reporter: ["text", "html", "lcov"],
include: ["src/**/*.ts"],
exclude: ["src/**/*.test.ts", "src/**/index.ts"],
thresholds: {
lines: 90,
functions: 90,
branches: 85,
statements: 90,
},
},
},
});