-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathvitest.config.ts
More file actions
37 lines (36 loc) · 1.1 KB
/
vitest.config.ts
File metadata and controls
37 lines (36 loc) · 1.1 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
import { resolve } from 'node:path'
import { defineConfig } from 'vitest/config'
export default defineConfig({
resolve: {
alias: {
'@': resolve(__dirname, 'src'),
'@lightscript/core': resolve(__dirname, 'packages/core/src'),
'@lightscript/dev': resolve(__dirname, 'packages/dev/src'),
},
},
test: {
coverage: {
exclude: ['node_modules/', 'dist/', 'scripts/'],
reporter: ['text', 'json', 'html'],
thresholds: {
global: {
branches: 70,
functions: 70,
lines: 70,
statements: 70,
},
},
},
environment: 'jsdom',
globals: true,
include: ['tests/**/*.test.ts', 'src/**/*.test.ts'],
// Enable parallel test execution
maxConcurrency: 4,
maxThreads: 4,
minThreads: 1,
// Fast test feedback
reporter: ['verbose', 'json'],
// Skip slow tests in watch mode
testTimeout: process.env.CI ? 10000 : 5000,
},
})