Skip to content

Commit 5f428d2

Browse files
committed
fix(db): preserve test connection URL parameters
1 parent 7932613 commit 5f428d2

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎packages/db/maintenance/search-retirement.integration.ts‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -672,6 +672,8 @@ describe('operator-driven Search retirement in PostgreSQL', () => {
672672

673673
it('the operator CLI refuses unverified endpoints and connection overrides before connecting', () => {
674674
const script = fileURLToPath(new URL('../scripts/retire-indexed-search.ts', import.meta.url))
675+
const overrideUrl = new URL(databaseUrl)
676+
overrideUrl.searchParams.set('statement_timeout', '0')
675677
for (const url of [
676678
'postgresql://reader@pool.example.invalid:5432/postgres',
677679
'postgresql://reader@fixture.pg.psdb.cloud:6432/postgres?sslmode=verify-full&sslrootcert=system',
@@ -680,7 +682,7 @@ describe('operator-driven Search retirement in PostgreSQL', () => {
680682
'postgresql://reader@fixture.pg.psdb.cloud:5432/postgres?sslmode=disable',
681683
'postgresql://fixture.pg.psdb.cloud:5432/postgres?sslmode=verify-full&sslrootcert=system',
682684
'postgresql://reader@fixture.pg.psdb.cloud:5432/?sslmode=verify-full&sslrootcert=system',
683-
`${databaseUrl}?statement_timeout=0`,
685+
overrideUrl.toString(),
684686
]) {
685687
const result = spawnSync('bun', ['--no-env-file', script, 'identity'], {
686688
env: { ...process.env, NODE_ENV: 'development', MIGRATION_DATABASE_URL: url },

0 commit comments

Comments
 (0)