-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathvitest.config.ts
52 lines (51 loc) · 1.28 KB
/
vitest.config.ts
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
import { mergeConfig, defineConfig } from "vitest/config"
import viteConfig from "./vite.config"
import path from "path"
export default defineConfig(() =>
mergeConfig(
viteConfig(),
defineConfig({
test: {
globals: true,
environment: "jsdom",
setupFiles: ["./tests/vitestSetup.ts"],
reporters: ["default", "junit"],
outputFile: {
junit: "./coverage/junit.xml"
},
coverage: {
provider: "v8",
reporter: ["html", "cobertura", "text", "text-summary", "lcov"],
exclude: [
"env.d.ts",
"src/**/*.d.ts",
"tests/**",
"node_modules/**",
"dist/**",
"docs/**",
"lib/**",
"lib_types/**",
".vitepress/**",
"**/{vite,vitest,eslint}.config.{js,cjs,mjs,ts}",
"src/hy-vue-gantt.ts",
"src/types/**",
],
reportsDirectory: "./coverage",
clean: true,
},
include: ["tests/**/*.test.ts"],
pool: "vmThreads",
poolOptions: {
threads: {
singleThread: true
}
}
},
resolve: {
alias: {
"@": path.resolve(__dirname, "./src")
}
}
})
)
)