Skip to content

Commit a4e1deb

Browse files
committed
Remove command checks in tests of pg_basebackup and pg_receivewal
The TAP tests of those commands have been checking if commands of "gzip" and "lz4" existed by launching them with an extra --version. Based on the buildfarm, this is not required for "gzip" as the command always exists. Since 1d084fb, "lz4" has a ./configure check doing the same thing. Reported-by: Andres Freund Discussion: https://postgr.es/m/20220212220643.ozuvq2k4cjkcnr2v@alap3.anarazel.de Discussion: https://postgr.es/m/Ygm2ADakjlqGc2Ro@paquier.xyz
1 parent a008496 commit a4e1deb

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

src/bin/pg_basebackup/t/010_pg_basebackup.pl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -767,9 +767,8 @@
767767
# Check the integrity of the files generated.
768768
my $gzip = $ENV{GZIP_PROGRAM};
769769
skip "program gzip is not found in your system", 1
770-
if ( !defined $gzip
771-
|| $gzip eq ''
772-
|| system_log($gzip, '--version') != 0);
770+
if (!defined $gzip
771+
|| $gzip eq '');
773772

774773
my $gzip_is_valid =
775774
system_log($gzip, '--test', @zlib_files, @zlib_files2, @zlib_files3);

src/bin/pg_basebackup/t/020_pg_receivewal.pl

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,8 @@
129129
# available.
130130
my $gzip = $ENV{GZIP_PROGRAM};
131131
skip "program gzip is not found in your system", 1
132-
if ( !defined $gzip
133-
|| $gzip eq ''
134-
|| system_log($gzip, '--version') != 0);
132+
if (!defined $gzip
133+
|| $gzip eq '');
135134

136135
my $gzip_is_valid = system_log($gzip, '--test', @zlib_wals);
137136
is($gzip_is_valid, 0,
@@ -185,9 +184,8 @@
185184
# command.
186185
my $lz4 = $ENV{LZ4};
187186
skip "program lz4 is not found in your system", 1
188-
if ( !defined $lz4
189-
|| $lz4 eq ''
190-
|| system_log($lz4, '--version') != 0);
187+
if (!defined $lz4
188+
|| $lz4 eq '');
191189

192190
my $lz4_is_valid = system_log($lz4, '-t', @lz4_wals);
193191
is($lz4_is_valid, 0,

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy