public inbox for [email protected]  
help / color / mirror / Atom feed
From: Andrew Dunstan <[email protected]>
To: Peter Eisentraut <[email protected]>
To: Andres Freund <[email protected]>
To: [email protected]
Subject: Re: Handle TEMP_CONFIG for pg_regress style tests in pg_regress.c
Date: Sun, 19 Feb 2023 08:58:59 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<[email protected]>


On 2023-02-19 Su 02:25, Peter Eisentraut wrote:
> On 18.02.23 21:26, Andres Freund wrote:
>> When building with meson, TEMP_CONFIG is supported for TAP tests, but 
>> doesn't
>> do anything for regress/isolation.
>>
>> The reason for that is that meson's (and ninja's) architecture is to 
>> separate
>> "build setup" from the "build/test/whatever" stage, moving dynamism 
>> (and more
>> costly operations) to the "setup" phase.
>>
>> In this case the implication is that the command line for the test isn't
>> re-computed dynamically. But pg_regress doesn't look at TEMP_CONFIG, 
>> it just
>> has a --temp-config=... parameter, that src/Makefile.global.in 
>> dynamically
>> adds if TEMP_CONFIG is set.
>>
>> In contrast to that, TEMP_CONFIG support for tap tests is implemented in
>> Cluster.pm, and thus works transparently.
>>
>> My inclination is to move TEMP_CONFIG support from the Makefile to
>> pg_regress.c. That way it's consistent across the build tools and isn't
>> duplicated. pg_regress already looks at a bunch of temporary variables
>> (e.g. PG_REGRESS_SOCK_DIR, PG_TEST_USE_UNIX_SOCKETS), so this isn't 
>> really
>> breaking new ground.
>
> I'm having a hard time understanding what TEMP_CONFIG is for.  It 
> appears that the intention is to allow injecting arbitrary 
> configuration into the tests?  In that case, I think your proposal 
> makes sense.  But I don't see this documented, so who knows what it is 
> actually used for.
>
>
>

It started here quite a long time ago:


commit 0cb74d3cec
Author: Andrew Dunstan <[email protected]>
Date:   Sun Sep 9 20:40:54 2007 +0000

     Provide for a file specifying non-standard config options for temp 
install
     for pg_regress, via --temp-config option. Pick this up in the make file
     via TEMP_CONFIG setting.

It's used by the buildfarm to add the extra config settings from its 
configuration file.


cheers


andrew


--
Andrew Dunstan
EDB:https://www.enterprisedb.com


view thread (2+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: Handle TEMP_CONFIG for pg_regress style tests in pg_regress.c
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox