/// import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import path from "path"; export default defineConfig({ plugins: [react()], test: { globals: true, environment: "jsdom", setupFiles: ["./tests/setup.ts"], include: ["tests/**/*.{test,spec}.{ts,tsx}"], exclude: ["tests/e2e/**", "**/node_modules/**"], coverage: { provider: "v8", reporter: ["text", "json", "html"], include: ["src/**/*.{ts,tsx}"], exclude: ["src/main.tsx", "src/**/*.d.ts"], }, // Mock Tauri APIs alias: { "@tauri-apps/api": path.resolve(__dirname, "./tests/mocks/tauri-api.ts"), }, }, resolve: { alias: { "@": path.resolve(__dirname, "./src"), }, }, });