On Wed, Aug 19, 2020 at 06:12:02PM +0900, Fujii Masao wrote: > On 2020/08/19 17:40, torikoshia wrote: >> Yes, I didn't add regression tests because of the unstability of the output. >> I thought it would be OK since other views like pg_stat_slru and >> pg_shmem_allocations >> didn't have tests for their outputs. > > You're right.
If you can make a test with something minimal and with a stable output, adding a test is helpful IMO, or how can you make easily sure that this does not get broken, particularly in the event of future refactorings, or even with platform-dependent behaviors? By the way, I was looking at the code that has been committed, and I think that it is awkward to have a SQL function in mcxt.c, which is a rather low-level interface. I think that this new code should be moved to its own file, one suggestion for a location I have being src/backend/utils/adt/mcxtfuncs.c. -- Michael
signature.asc
Description: PGP signature