Files
ExcaliDash/backend/vitest.config.ts
T
Zimeng Xiong e4e48b13d8 chore: clean up CSRF implementation
- Remove unused generateCsrfToken export from security.ts
  - Remove redundant /csrf-token path check (GET already exempt)
  - Restore defineConfig wrapper in vitest.config.ts for type safety
2026-01-14 08:21:49 -08:00

24 lines
526 B
TypeScript

import { defineConfig } from "vitest/config";
export default defineConfig({
test: {
globals: true,
environment: "node",
include: ["src/**/*.test.ts", "src/**/*.integration.ts"],
testTimeout: 30000,
hookTimeout: 30000,
// Use a separate test database
env: {
DATABASE_URL: "file:./prisma/test.db",
NODE_ENV: "test",
},
// Run tests sequentially to avoid database conflicts
pool: "forks",
poolOptions: {
forks: {
singleFork: true,
},
},
},
});