Re: Unit tests for SLRU
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Aleksander Alekseev <aleksander@timescale.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Pavel Borisov <pashkin.elfe@gmail.com>, Peter Eisentraut <peter.eisentraut@enterprisedb.com>, Maxim Orlov <orlovmg@gmail.com>, Noah Misch <noah@leadboat.com>, Daniel Gustafsson <daniel@yesql.se>
Date: 2022-11-11T05:11:08Z
Lists: pgsql-hackers
On Thu, Nov 10, 2022 at 06:40:44PM +0300, Aleksander Alekseev wrote: > Fair enough. PFA the corrected patch v5. Is there a reason why you need a TAP test here? It is by design more expensive than pg_regress and it does not require --enable-tap-tests. See for example what we do for snapshot_too_old, commit_ts, worker_spi, etc., where each module uses a custom configuration file. Hmm. If I were to write that, I think that I would make the SLRU directory configurable as a PGC_POSTMASTER, at least, for the purpose of the exercise, and also split test_slru() into more user-callable functions so as it would be possible to mix more cross-check scenarios with the low-level C APIs if need be, with adapted input parameters. -- Michael
Commits
-
Add test module for SLRUs
- 006b69fd912b 16.0 landed
-
Fix comment of SimpleLruInit() in slru.c
- 9e0321135cae 14.7 landed
- 5962c8cbe5a6 15.2 landed
- 5ca3645cb3fb 16.0 landed