-
Notifications
You must be signed in to change notification settings - Fork 3
/
vitest.workspace.ts
85 lines (79 loc) · 1.72 KB
/
vitest.workspace.ts
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
import { defineWorkspace } from 'vitest/config';
export default defineWorkspace([
// you can use a list of glob patterns to define your workspaces
// Vitest expects a list of config files
// or directories where there is a config file
// 'packages/*',
// 'tests/*/vitest.config.{e2e,unit}.ts',
// // you can even run the same tests,
// // but with different configs in the same "vitest" process
{
test: {
name: 'store',
root: './packages/store',
environment: 'jsdom',
setupFiles: ['./test-setup.ts'],
// setupFiles: ['./setup.happy-dom.ts'],
},
},
{
test: {
name: 'service',
root: './packages/service',
environment: 'node',
typecheck: {
enabled: true,
include: ['**/*.test.ts'],
},
// setupFiles: ['./test-setup.ts'],
// setupFiles: ['./setup.happy-dom.ts'],
},
},
{
test: {
name: 'action',
root: './packages/action',
environment: 'node',
// typecheck: {
// enabled: true,
// include: ['**/*.test.ts'],
// },
// setupFiles: ['./test-setup.ts'],
// setupFiles: ['./setup.happy-dom.ts'],
},
},
{
test: {
name: 't3-app',
root: './examples/t3-with-davstack',
environment: 'node',
typecheck: {
enabled: true,
include: ['**/*.test.ts'],
},
// setupFiles: ['./test-setup.ts'],
// setupFiles: ['./setup.happy-dom.ts'],
},
},
{
test: {
name: 'sound',
root: './packages/sound',
environment: 'jsdom',
typecheck: {
enabled: false,
include: ['**/*.test.ts'],
},
// setupFiles: ['./test-setup.ts'],
// setupFiles: ['./setup.happy-dom.ts'],
},
},
// {
// test: {
// name: 'node',
// root: './shared_tests',
// environment: 'node',
// setupFiles: ['./setup.node.ts'],
// },
// },
]);