Re: pgsql: Clean up role created in new subscription test. - Mailing list pgsql-hackers

From Daniel Gustafsson
Subject Re: pgsql: Clean up role created in new subscription test.
Date
Msg-id FC40D564-3286-4AE7-A15A-926810300110@yesql.se
Whole thread Raw
In response to Re: pgsql: Clean up role created in new subscription test.  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
List pgsql-hackers
> On 8 Nov 2023, at 13:32, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
>
> On 2023-Nov-08, Daniel Gustafsson wrote:
>
>> Since test_setup.sql is part of the regress schedule and not pg_regress we
>> would have to implement this for each test run (regress, contribs etc), which
>> is what Peter didn't like about the original suggestion.
>
> Oh, somehow that aspect of his reply failed to register with me.  I
> agree with your approach of using libpq in pg_regress then.
>
> I suppose you're just thinking of using PQexec() or whatever, run one
> query with sufficient ORDER BY, save the result, and at the end of the
> test run just run the same query and compare that they are cell-by-cell
> identical?  This sounds a lot simpler than the patch you posted.

Correct, that's my plan.  The rationale for the earlier patch was to avoid
adding a dependency on libpq, but with that already discussed and done we can
leverage the fact that we can run such queries easy.

--
Daniel Gustafsson




pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Syncrep and improving latency due to WAL throttling
Next
From: Matthias van de Meent
Date:
Subject: Re: Add new option 'all' to pg_stat_reset_shared()