mirror of
https://github.com/kamask-dev/pchelpmaster.git
synced 2026-11-11 13:59:38 +00:00
`pnpm test:api` starts an isolated PocketBase with project migrations and hooks in a temp dir, provides SDK client helpers and cleans up after the run, on failure and on SIGINT/SIGTERM. The superuser is generated per instance. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EvmtStx737hu8gXe15e55W
7 lines
295 B
TypeScript
7 lines
295 B
TypeScript
// Starts PocketBase and holds it until the process gets a signal; used to test cleanup on Ctrl+C.
|
|
import { startPocketBase } from '../pocketbase-server.ts';
|
|
|
|
const { url, dataDir } = await startPocketBase();
|
|
console.log(JSON.stringify({ url, dataDir }));
|
|
setInterval(() => undefined, 1 << 30);
|