-
Notifications
You must be signed in to change notification settings - Fork 127
Expand file tree
/
Copy pathvitest.config.ts
More file actions
33 lines (32 loc) · 1.04 KB
/
vitest.config.ts
File metadata and controls
33 lines (32 loc) · 1.04 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
// (C) 2023-2025 GoodData Corporation
import { defineConfig } from "vitest/config";
// eslint-disable-next-line no-restricted-exports
export default defineConfig({
resolve: {
preserveSymlinks: true,
},
test: {
// Use happy-dom for faster performance than jsdom
environment: "happy-dom",
setupFiles: "./vitest.setup.ts",
pool: "threads",
maxWorkers: 8, // Thread count for CI
// Improve performance with these options
isolate: true,
maxConcurrency: 8, // Concurrency for CI
// Disable slow operations when not needed
globals: false,
// Speed up test runs by avoiding unnecessary operations
environmentOptions: {
"happy-dom": {
url: "http://localhost",
// Disable features not needed for tests
features: {
FetchAPI: false,
WebSocket: false,
ProcessExternalResources: false,
},
},
},
},
});