Mop-up from Test::More version change patch

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-hackers(at)lists(dot)postgresql(dot)org
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Noah Misch <noah(at)leadboat(dot)com>
Subject: Mop-up from Test::More version change patch
Date: 2021-11-23 17:03:05
Message-ID: 36086.1637686985@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

[ moving thread to -hackers for a bit more visibility ]

Attached are a couple of patches I propose in the wake of commit
405f32fc4 (Require version 0.98 of Test::More for TAP tests).

0001 responds to the failure we saw on buildfarm member wrasse [1]
where, despite configure having carefully checked for Test::More
being >= 0.98, actual tests failed with
Test::More version 0.98 required--this is only version 0.92 at /export/home/nm/farm/studio64v12_6/HEAD/pgsql.build/../pgsql/src/test/perl/PostgreSQL/Test/Utils.pm line 63.
The reason is that wrasse was choosing "prove" from a different
Perl installation than "perl", as a result of its configuration
having set PERL to a nondefault place but doing nothing about PROVE.

We already installed a couple of mitigations for that:
(a) as of c4fe3199a, configure checks "prove" not "perl" for
appropriate module versions;
(b) Noah has modified wrasse's configuration to set PROVE.
But I'm of the opinion that (b) should not be necessary.
If you set PERL then it's highly likely that you want to use
"prove" from the same installation. So 0001 modifies configure
to first check for an executable "prove" in the same directory
as $PERL. If that's not what you want then you should override
it by setting PROVE explicitly.

Since this is mainly meant to prevent an easy-to-make error in
setting up buildfarm configurations, we should back-patch it.

0002 is written to apply to v14 and earlier, and what it wants
to do is back-patch the effects of 405f32fc4, so that the
minimum Test::More version is 0.98 in all branches. The thought
here is that (1) somebody is likely to want to back-patch a
test involving Test::More::subtest before too long; (2) we have
zero coverage for older Test::More versions anyway, now that
all buildfarm members have been updated to work with HEAD.

Any objections?

regards, tom lane

[1] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=wrasse&dt=2021-11-20%2022%3A58%3A17

Attachment Content-Type Size
0001-prefer-sibling-prove.patch text/x-diff 2.1 KB
0002-require-Test-More-0.98-in-back-branches.patch text/x-diff 946 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jacob Champion 2021-11-23 18:27:38 Post-CVE Wishlist
Previous Message John Naylor 2021-11-23 16:59:00 Re: [Proposal] Fully WAL logged CREATE DATABASE - No Checkpoints