-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvitest.config.monaco.ts
More file actions
40 lines (39 loc) · 1.14 KB
/
vitest.config.monaco.ts
File metadata and controls
40 lines (39 loc) · 1.14 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
import { defineConfig } from "vitest/config";
import { resolve } from "path";
export default defineConfig({
test: {
globals: true,
environment: "jsdom",
setupFiles: ["./src/__tests__/setup.ts"],
coverage: {
provider: "v8",
reporter: ["text", "json", "html"],
exclude: ["node_modules/", "src/__tests__/", "**/*.d.ts", "**/*.config.*", "**/stories/**"]
}
},
resolve: {
alias: {
"@": resolve(__dirname, "./src"),
"monaco-editor": resolve(__dirname, "./src/__tests__/mocks/monaco-editor.js"),
"monaco-editor/esm/vs/editor/editor.api": resolve(
__dirname,
"./src/__tests__/mocks/monaco-editor/esm/vs/editor/editor.api.js"
),
"@making-sense/antlr4ng": resolve(__dirname, "./src/__tests__/mocks/antlr4ng.js")
}
},
define: {
global: "globalThis"
},
optimizeDeps: {
exclude: ["monaco-editor", "@monaco-editor/react"]
},
esbuild: {
target: "es2020"
},
server: {
fs: {
allow: [".."]
}
}
});