refactor: expose additional kysely postgres options

This commit is contained in:
dswbx
2025-11-05 10:47:47 +01:00
parent a333d537b0
commit 40bbdb904f
4 changed files with 28 additions and 21 deletions

View File

@@ -28,7 +28,7 @@ async function cleanDatabase(connection: InstanceType<typeof PostgresConnection>
async function isPostgresRunning() {
try {
// Try to actually connect to PostgreSQL
const conn = pg(new Pool(credentials));
const conn = pg({ pool: new Pool(credentials) });
await conn.ping();
await conn.close();
return true;
@@ -58,8 +58,8 @@ describe("postgres", () => {
});
describe.serial.each([
["pg", () => pg(new Pool(credentials))],
["postgresjs", () => postgresJs(postgres(credentials))],
["pg", () => pg({ pool: new Pool(credentials) })],
["postgresjs", () => postgresJs({ postgres: postgres(credentials) })],
])("%s", (name, createConnection) => {
connectionTestSuite(
{