-
Notifications
You must be signed in to change notification settings - Fork 1
/
vitest.config.ts
36 lines (35 loc) · 1.01 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
/// <reference types="vitest" />
/// <reference types="vite/client" />
import { defineConfig } from "vitest/config";
import tsconfigPaths from "vite-tsconfig-paths";
import react from "@vitejs/plugin-react";
export default defineConfig({
plugins: [tsconfigPaths(), react()],
define: {
"import.meta.vitest": false,
},
test: {
globals: true,
environment: "jsdom",
coverage: {
all: true,
provider: "v8",
reporter: ["text", "json", "html"],
exclude: ["src/util/type.ts", "src/server/util/type.ts", "tests/**"],
},
includeSource: ["src/**/*.{ts,tsx}", "tests/**/*.{ts}"],
include: [
"**/*.{test,spec}.{js,ts,jsx,tsx}",
"./tests/**/*.{test,spec}.{js,ts,jsx,tsx}",
],
exclude: ["**/node_modules/**"],
setupFiles: ["tests/setup.ts"],
testTimeout: 50000,
env: {
NODE_ENV: "test",
FIREBASE_AUTH_EMULATOR_HOST: "localhost:9099",
FIRESTORE_EMULATOR_HOST: "localhost:8080",
GCLOUD_PROJECT: "swr-firestore-project",
}
},
});