-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathvitest.config.ts
More file actions
42 lines (41 loc) · 1.24 KB
/
vitest.config.ts
File metadata and controls
42 lines (41 loc) · 1.24 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
import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
// Vitest 2 exits non-zero on empty test suites by default; remove this flag
// once test files exist in every workspace package.
passWithNoTests: true,
globals: false,
environment: 'node',
include: ['**/*.{test,spec}.{ts,tsx}'],
// `e2e/**` is excluded because Playwright owns those specs — they
// import `@playwright/test` and would crash Vitest with a missing
// global `test` reference. The Playwright runner picks them up via
// `playwright.config.ts` instead. Both relative and `**/e2e/**`
// patterns are listed because the workspace projects resolve
// includes/excludes against their own root, so a single `**`
// pattern is not enough for both root + workspace scopes.
exclude: [
'node_modules',
'dist',
'out',
'.idea',
'.git',
'.cache',
'**/e2e/**',
'e2e/**',
'apps/desktop/e2e/**',
],
coverage: {
provider: 'v8',
reporter: ['text', 'lcov', 'html'],
exclude: [
'**/node_modules/**',
'**/dist/**',
'**/out/**',
'**/*.d.ts',
'**/*.config.*',
'**/test-utils/**',
],
},
},
});