forked from ticlo/ticlo
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvitest.web.config.mts
More file actions
72 lines (70 loc) · 1.8 KB
/
vitest.web.config.mts
File metadata and controls
72 lines (70 loc) · 1.8 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
import {defineConfig} from 'vitest/config';
import react from '@vitejs/plugin-react';
import {nodePolyfills} from 'vite-plugin-node-polyfills';
import tsconfigPaths from 'vite-tsconfig-paths';
export default defineConfig({
plugins: [tsconfigPaths(), react(), nodePolyfills()],
server: {
fs: {
allow: ['..']
},
watch: {
// Disable file watching in WSL to prevent reload issues
ignored: ['**/node_modules/**', '**/.git/**'],
usePolling: true,
interval: 1000
}
},
test: {
browser: {
provider: 'webdriverio',
enabled: true,
// at least one instance is required
instances: [
{
browser: 'chrome',
capabilities: {
'browserName': 'chrome',
'webSocketUrl': true,
'goog:chromeOptions': {
args: [
'--headless=new',
'--disable-gpu',
'--disable-dev-shm-usage',
'--no-sandbox',
'--disable-setuid-sandbox',
'--disable-web-security',
'--disable-features=VizDisplayCompositor'
],
},
},
},
],
},
testTimeout: 30000,
hookTimeout: 30000,
isolate: false,
globals: true,
include: [
'packages/core/**/*.spec.ts',
'packages/html/**/*.spec.ts',
'packages/react/**/*.spec.(ts|tsx)',
'packages/editor/**/*.spec.(ts|tsx)',
],
setupFiles: ['packages/html/vitest.setup.ts'],
coverage: {
provider: 'istanbul',
reporter: ['lcov'],
reportsDirectory: './coverage/browser',
},
exclude: [
'**/node_modules/**',
'**/dist/**',
'**/cypress/**',
'**/.{idea,git,cache,output,temp}/**',
'bin/**',
'example/**',
'tool/**',
],
},
});