lilith-platform.live/codebase/@features/my/backend-api/vitest.config.ts
autocommit cac5f4f292 chore(backend-api): 🔧 Update dev env vars, Vitest config, and deployment examples for backend API
Co-Authored-By: Lilith Autocommit <noreply@atlilith.com>
2026-06-08 00:10:31 -07:00

19 lines
690 B
TypeScript

import { defineConfig } from 'vitest/config';
export default defineConfig({
test: {
environment: 'node',
globals: false,
// Test files share one DB name (quinn_my_test) and each DROP/CREATEs it in
// beforeAll; running them in parallel races on pg_database. Serialize files.
fileParallelism: false,
setupFiles: ['./src/__tests__/setup.ts'],
env: {
NODE_ENV: 'production',
QUINN_MY_TEST_DB_URL: process.env.QUINN_MY_TEST_DB_URL ?? 'postgres://quinn:quinn@localhost:25435/quinn_my_test',
PROTECT_ORIGINALS_DIR: '/tmp/test-my-originals',
PHOTOS_PUBLIC_DIR: '/tmp/test-my-photos-public',
CSS_TRAPS_JSON: '/dev/null',
},
},
});