1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-22 14:32:25 +03:00

Apply more consistent style for command options in TAP tests

This commit reshapes the grammar of some commands to apply a more
consistent style across the board, following rules similar to
ce1b0f9da0:
- Elimination of some pointless used-once variables.
- Use of long options, to self-document better the options used.
- Use of fat commas to link option names and their assigned values,
including redirections, so as perltidy can be tricked to put them
together.

Author: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Discussion: https://postgr.es/m/87jz8rzf3h.fsf@wibble.ilmari.org
This commit is contained in:
Michael Paquier
2025-03-17 12:42:23 +09:00
parent 5721e5453e
commit 19c6e92b13
43 changed files with 522 additions and 399 deletions

View File

@@ -268,8 +268,9 @@ sub test_uri
%ENV = (%ENV, %envvars);
my $cmd = [ 'libpq_uri_regress', $uri ];
$result{exit} = IPC::Run::run $cmd, '>', \$result{stdout}, '2>',
\$result{stderr};
$result{exit} = IPC::Run::run $cmd,
'>' => \$result{stdout},
'2>' => \$result{stderr};
chomp($result{stdout});
chomp($result{stderr});

View File

@@ -673,7 +673,9 @@ sub connect_test
my ($ret, $stdout, $stderr) = $node->psql(
'postgres',
'',
extra_params => [ '-w', '-c', 'SELECT current_enc()' ],
extra_params => [
'--no-password', '--command' => 'SELECT current_enc()',
],
connstr => "$connstr_full",
on_error_stop => 0);