-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvitest.config.mts
More file actions
30 lines (28 loc) · 914 Bytes
/
vitest.config.mts
File metadata and controls
30 lines (28 loc) · 914 Bytes
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
/**
* Extends shared vitest config.
* Uses forks pool with singleFork for codesigning compatibility.
*
* IMPORTANT: Must use forks pool with singleFork=true because:
* 1. Codesigning operations on macOS can leave file handles open
* 2. Multiple concurrent test processes can cause race conditions
* 3. Sequential execution in single fork prevents these issues
*/
import { defineConfig, mergeConfig } from 'vitest/config'
import baseConfig from '../../vitest.config.mts'
export default mergeConfig(
baseConfig,
defineConfig({
test: {
// Use forks pool for full process isolation (required for codesigning)
pool: 'forks',
poolOptions: {
forks: {
// Run all tests in single fork sequentially (prevents codesign race conditions)
singleFork: true,
// Full isolation between test files
isolate: true,
},
},
},
}),
)