-
Notifications
You must be signed in to change notification settings - Fork 1.2k
/
vitest.shared.config.ts
43 lines (41 loc) · 1.04 KB
/
vitest.shared.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
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { defineConfig } from "vitest/config";
export default defineConfig({
test: {
testTimeout: 18000,
reporters: ["verbose", "junit"],
outputFile: {
junit: "test-results.xml",
},
fakeTimers: {
toFake: ["setTimeout", "Date"],
},
watch: false,
include: ["test/**/*.spec.ts"],
exclude: [
"test/**/browser/*.spec.ts",
"test/snippets.spec.ts",
"test/integration/**/*.spec.ts",
"test/stress/**/*.ts",
],
coverage: {
include: ["src/**/*.ts"],
exclude: [
"src/**/*-browser.mts",
"src/**/*-react-native.mts",
"vitest*.config.ts",
"samples-dev/**/*.ts",
"test/snippets.spec.ts",
],
provider: "istanbul",
reporter: ["text", "json", "html"],
reportsDirectory: "coverage",
},
typecheck: {
enabled: true,
tsconfig: "tsconfig.test.json",
include: ["test/**/*.ts", "test/**/*.mts", "test/**/*.cts"],
},
},
});