Re: Running a single test - Mailing list pgsql-hackers

From jian he
Subject Re: Running a single test
Date
Msg-id CACJufxHOcmeTkoh2CxFHKv9GRnp9sLVzN=LZhqTgvqT++PXZNQ@mail.gmail.com
Whole thread Raw
In response to Running a single test  (Viktor Holmberg <v@viktorh.net>)
List pgsql-hackers
On Mon, Nov 17, 2025 at 6:27 PM Viktor Holmberg <v@viktorh.net> wrote:
>
> Hello hackers
>
> Apologies if this is a n00b question - but really can’t find anything about it in the docs.
> I can run all the regression tests with `make test`. But is there a way to run a single specific test?
> It’d be nice to do this for example when adding extra assertions to a test, without touching the code.
>
hi.

run test_setup.sql, boolean.sql, char.sql tests only
you can use

make check-tests TESTS="test_setup boolean char"

this is not documented, see
https://postgr.es/m/CA+renyXB5jYG9r5-CaDc4g607EB398QwTk_efEXTzarrO8bPzw@mail.gmail.com


meson,
there is patch available:
https://commitfest.postgresql.org/patch/5405/

after apply the patch, you can use
meson test -C $your_build_dir --suite setup --verbose
TESTS='test_setup boolean char' meson test -C $your_build_dir --suite
regress --verbose



pgsql-hackers by date:

Previous
From: Chao Li
Date:
Subject: Fix a couple of misspellings in comments of logic replication
Next
From: Daniel Gustafsson
Date:
Subject: Re: [Patch] Mention md5 is deprecated in postgresql.conf.sample