import { defineConfig } from "vitest/config" import tsconfigPaths from "vite-tsconfig-paths" export default defineConfig({ plugins: [ tsconfigPaths({ root: ".", projects: ["./tsconfig.json", "./tests/tsconfig.json"], }), ], test: { globals: true, root: ".", globalSetup: "./tests/global-setup.ts", setupFiles: ["./tests/setup.ts"], isolate: true, poolOptions: { forks: { singleFork: true, }, }, forceRerunTriggers: [ "**/*.(html|txt)", // Rerun tests when data files change ], // Mocking clearMocks: true, mockReset: true, restoreMocks: true, unstubEnvs: true, unstubGlobals: true, }, })