mirror of
https://github.com/postgres/postgres.git
synced 2025-06-11 20:28:21 +03:00
Specify the port in dblink and postgres_fdw tests.
That allows to run those tests against a postmaster listening on a nonstandard port without requiring to export PGPORT in postmaster's environment. This still doesn't support connecting to a nondefault host without configuring it in postmaster's environment. That's harder and less frequently used though. So this is a useful step.
This commit is contained in:
@ -8,7 +8,9 @@ CREATE SERVER testserver1 FOREIGN DATA WRAPPER postgres_fdw;
|
||||
DO $d$
|
||||
BEGIN
|
||||
EXECUTE $$CREATE SERVER loopback FOREIGN DATA WRAPPER postgres_fdw
|
||||
OPTIONS (dbname '$$||current_database()||$$');$$;
|
||||
OPTIONS (dbname '$$||current_database()||$$',
|
||||
port '$$||current_setting('port')||$$'
|
||||
)$$;
|
||||
END;
|
||||
$d$;
|
||||
|
||||
|
Reference in New Issue
Block a user