supabase-test
Version:
supabase-test offers isolated, role-aware, and rollback-friendly PostgreSQL environments for integration tests with Supabase defaults baked in
12 lines (11 loc) • 640 B
TypeScript
import { getConnections as getPgConnections, type GetConnectionOpts, type GetConnectionResult } from 'pgsql-test';
/**
* Get connections with Supabase defaults applied.
* Environment variables take precedence over Supabase defaults.
* User-provided options take precedence over both.
*
* Note: Uses PGUSER/PGPASSWORD for both pg config and db.connection
* (DB_CONNECTION_ROLE can still be used to override the default role)
*/
export declare const getConnections: (cn?: GetConnectionOpts, seedAdapters?: Parameters<typeof getPgConnections>[1]) => Promise<GetConnectionResult>;
export type { GetConnectionOpts, GetConnectionResult };