-
Notifications
You must be signed in to change notification settings - Fork 27
/
Copy pathvitest.config.ts
53 lines (52 loc) · 1.33 KB
/
vitest.config.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
// eslint-disable-next-line import/no-extraneous-dependencies
import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
coverage: {
exclude: [
'packages/**/dist/**',
'packages/httpsnippet-client-api/test/__datasets__/**',
'packages/test-utils/sdks/**',
],
},
env: {
// Vitest strips colors from content by default and `chalk` has troubles with color detection
// in CI.
// https://github.com/chalk/supports-color/issues/106
FORCE_COLOR: '1',
},
exclude: [
'**/__fixtures__/**',
'**/__datasets__/**',
'**/datasets/**',
'**/dist/**',
'**/helpers/**',
'**/node_modules/**',
],
setupFiles: ['packages/test-utils/vitest.matchers.ts', 'packages/test-utils/vitest.setup.ts'],
workspace: [
{
extends: true,
test: {
exclude: ['**/smoketest.test.ts'],
include: ['packages/api/**/*.test.ts'],
name: 'api',
},
},
{
extends: true,
test: {
include: ['packages/core/**/*.test.ts'],
name: 'core',
},
},
{
extends: true,
test: {
include: ['packages/httpsnippet-client-api/**/*.test.ts'],
name: 'httpsnippet-client-api',
},
},
],
},
});