Force tests to run on kyoo_test database

This commit is contained in:
2025-11-23 22:41:52 +01:00
parent 7ebc0fe504
commit 20ab1dae6c
3 changed files with 6 additions and 2 deletions
+3 -1
View File
@@ -1,9 +1,11 @@
import { beforeAll } from "bun:test";
import { migrate } from "~/db";
process.env.PGDATABASE = "kyoo_test";
process.env.JWT_SECRET = "this is a secret";
process.env.JWT_ISSUER = "https://kyoo.zoriya.dev";
beforeAll(async () => {
// lazy load this so env set before actually applies
const { migrate } = await import("~/db");
await migrate();
});