From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Daniel Gustafsson <daniel(at)yesql(dot)se> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pgsql: Clean up role created in new subscription test. |
Date: | 2023-03-30 20:29:36 |
Message-ID: | 284965.1680208176@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers pgsql-hackers |
Daniel Gustafsson <daniel(at)yesql(dot)se> writes:
>> On 30 Mar 2023, at 20:44, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Maybe it'd be close enough to expect there to be no roles named
>> "regress_xxx". In combination with
>> -DENFORCE_REGRESSION_TEST_NAME_RESTRICTIONS, that would prevent us
>> from accidentally leaving stuff behind, and we could hope that it doesn't
>> cause false failures in real installations.
> Would that check be always on or only when pg_regress is compiled with
> -DENFORCE_REGRESSION_TEST_NAME_RESTRICTIONS?
I envisioned it as being on all the time.
>> Another idea could be for pg_regress to enforce that "select count(*)
>> from pg_roles" gives the same answer before and after the test run.
> That wouldn't prevent the contents of pg_roles to have changed though, so there
> is a (slim) false positive risk with that no?
Well, we could do "select rolname from pg_roles order by 1" and
actually compare the results of the two selects. That might be
advisable anyway, in order to produce a complaint with useful
detail when there is something wrong.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Gustafsson | 2023-03-30 20:53:03 | Re: pgsql: Clean up role created in new subscription test. |
Previous Message | Peter Geoghegan | 2023-03-30 19:27:14 | pgsql: Show record information in pg_get_wal_block_info. |
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Gustafsson | 2023-03-30 20:53:03 | Re: pgsql: Clean up role created in new subscription test. |
Previous Message | Peter Eisentraut | 2023-03-30 20:10:02 | Re: Transparent column encryption |