Re: Is pg_regress --use-existing used by anyone or is it broken?

From: Peter Geoghegan <pg(at)bowt(dot)ie>
To: Daniel Gustafsson <daniel(at)yesql(dot)se>
Cc: Nathan Bossart <nathandbossart(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Is pg_regress --use-existing used by anyone or is it broken?
Date: 2023-08-29 22:55:23
Message-ID: CAH2-WznkTFtppbY9g4cgWPr0zrBoi6=jOu5AH+nbdf3GOYjbMQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Aug 29, 2023 at 3:37 PM Daniel Gustafsson <daniel(at)yesql(dot)se> wrote:
> > It's handy when using pg_regress with a custom test suite, where I
> > don't want to be nagged about disconnecting from the database every
> > time.
>
> I'm curious about your workflow around it, it seems to me that it's kind of
> broken so I wonder if we instead then should make it an equal citizen with temp
> instance?

I'm confused. You seem to think that it's a problem that
--use-existing doesn't create databases and roles. But that's the
whole point, at least for me.

I don't use --use-existing to run the standard regression tests, or
anything like that. I use it to run my own custom test suite, often
while relying upon the database having certain data already. Sometimes
it's a nontrivial amount of data. I don't want to have to set up and
tear down the data every time, since it isn't usually necessary.

I usually have a relatively small and fast running read-only test
suite, and a larger test suite that does indeed need to do various
setup and teardown steps. It isn't possible to run the smaller test
suite without having first run the larger one at least once. But this
is just for me, during development. Right now, with my SAOP nbtree
project, the smaller test suite takes me about 50ms to run, while the
larger one takes almost 10 seconds.

--
Peter Geoghegan

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2023-08-29 22:55:49 Re: Autogenerate some wait events code and documentation
Previous Message Daniel Gustafsson 2023-08-29 22:37:03 Re: Is pg_regress --use-existing used by anyone or is it broken?