Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/openstatusHQ/openstatus. ๐ซ Status page with uptime monitoring & API monitoring as code ๐ซ openstatus.dev
bun drizzle-orm monitoring monitoring-as-code nextjs observability on-call open-source shadcn-ui status-page statuspage synthetic-monitoring tinybird turso uptime uptime-checker uptime-monitor
Something went wrong. Try again.
663 B ยท 14 lines
TypeScript
123456789101112131415// Bun test preload. Runs once before any test file is imported.//// `packages/services/src/status-report/notify.ts` imports// `@openstatus/subscriptions`, which transitively imports// `@openstatus/emails`. `@openstatus/emails` validates `RESEND_API_KEY`// via `@t3-oss/env-core` at module-load time and throws on missing.//// Tests never exercise the real dispatch path โ they assert on db state// and audit rows. Stubbing the env var lets the import graph resolve// without plumbing a real Resend key (which CI / local dev shouldn't// need just to run unit tests).if (!process.env.RESEND_API_KEY) { process.env.RESEND_API_KEY = "re_test_stub";}