-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathvitest.config.ts
More file actions
38 lines (37 loc) · 1.1 KB
/
vitest.config.ts
File metadata and controls
38 lines (37 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
38
import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
include: [
'test/index.test.ts',
'test/detect-port-enhanced.test.ts',
'test/detect-port-advanced.test.ts',
'test/detect-port-mocking.test.ts',
'test/detect-port-spy.test.ts',
'test/wait-port-enhanced.test.ts',
'test/cli-enhanced.test.ts',
'test/integration.test.ts',
],
coverage: {
provider: 'v8',
reporter: ['text', 'json', 'html'],
include: ['src/**/*.ts'],
exclude: [
'src/**/*.d.ts',
'src/bin/**', // CLI is tested but coverage not tracked via vitest
],
all: true,
// Coverage thresholds
// Note: Some edge case error handling paths (6 lines) in detect-port.ts are
// difficult to test without extensive mocking as they require specific
// system conditions (DNS failures, port 0 failures, specific binding errors)
thresholds: {
lines: 93,
functions: 100,
branches: 90,
statements: 93,
},
},
testTimeout: 10000,
hookTimeout: 10000,
},
});