Re: RFC: adding pytest as a supported test framework

From: "Jelte Fennema-Nio" <postgres(at)jeltef(dot)nl>
To: "Jacob Champion" <jacob(dot)champion(at)enterprisedb(dot)com>
Cc: "Andres Freund" <andres(at)anarazel(dot)de>, "PostgreSQL Hackers" <pgsql-hackers(at)postgresql(dot)org>, "Robert Haas" <robertmhaas(at)gmail(dot)com>, "Daniel Gustafsson" <daniel(at)yesql(dot)se>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Peter Eisentraut" <peter(at)eisentraut(dot)org>, "Nazir Bilal Yavuz" <byavuz81(at)gmail(dot)com>
Subject: Re: RFC: adding pytest as a supported test framework
Date: 2026-01-08 12:49:44
Message-ID: DFJ7Y36W9C86.3K416WEM16SJF@jeltef.nl
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed Jan 7, 2026 at 2:01 AM CET, Jacob Champion wrote:
> It's perfectly okay if you'd like to tie the GoAway proposal to this,
> but that seems like it's unlikely to result in short-term success.

To be clear, I did not mean to tie the GoAway proposal to this. I meant
to tie committing of *automated tests* for GoAway to this. Given how
little of our libpq interface is tested, I don't think that needs to be
a blocker for the GoAway feature itself.

Timing wise, I'd myself much rather have this patchset as an early PG20
commit than a last minute PG19 one.

> Writing code to start and stop a server and run SQL is a matter of
> programming. Writing a test suite that newcomers can intuitively use,
> and test interesting new things with, is a long-term collaboration. I
> am much more interested in doing the latter, because we already have
> the former, and personally I'm happy to build momentum slowly and wait
> on a group of people who are in a good place to discuss it.

Sure, it's a matter of programming. But my feeling is that most people
on the list don't want to build their own test infrastructure. They want
good infrastructure to "just exist", so they can write tests easily with
it.

So that's why after trying to use your initial attempt for a test of
mine, I moved the useful parts to a shared part of the codebase. So that
people can easily try writing a test with it, and explain what they like
or don't like. Instead of having to create or copy a bunch of
boilerplate every time they want to do something.

In any case, that's where we're at now. It would be nice if you could
take a look at the actual patchset at some point, but no rush.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Chao Li 2026-01-08 13:02:11 Re: Refactor replication origin state reset helpers
Previous Message Jelte Fennema-Nio 2026-01-08 12:34:57 Re: RFC: adding pytest as a supported test framework