1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-08 06:02:22 +03:00

Initial pgperltidy run for v12.

Make all the perl code look nice, too (for some value of "nice").
This commit is contained in:
Tom Lane
2019-05-22 13:36:19 -04:00
parent 8255c7a5ee
commit db6e2b4c52
38 changed files with 487 additions and 384 deletions

View File

@@ -26,6 +26,7 @@ open my $conf, '>>', "$tempdir/data/postgresql.conf";
print $conf "fsync = off\n";
print $conf TestLib::slurp_file($ENV{TEMP_CONFIG})
if defined $ENV{TEMP_CONFIG};
if (!$windows_os)
{
print $conf "listen_addresses = ''\n";

View File

@@ -25,8 +25,10 @@ my $current_logfiles = slurp_file($node->data_dir . '/current_logfiles');
note "current_logfiles = $current_logfiles";
like($current_logfiles, qr|^stderr log/postgresql-.*log$|,
'current_logfiles is sane');
like(
$current_logfiles,
qr|^stderr log/postgresql-.*log$|,
'current_logfiles is sane');
my $lfname = $current_logfiles;
$lfname =~ s/^stderr //;
@@ -43,8 +45,7 @@ for (my $attempts = 0; $attempts < $max_attempts; $attempts++)
usleep(100_000);
}
like($first_logfile, qr/division by zero/,
'found expected log file content');
like($first_logfile, qr/division by zero/, 'found expected log file content');
# Sleep 2 seconds and ask for log rotation; this should result in
# output into a different log file name.
@@ -63,8 +64,10 @@ for (my $attempts = 0; $attempts < $max_attempts; $attempts++)
note "now current_logfiles = $new_current_logfiles";
like($new_current_logfiles, qr|^stderr log/postgresql-.*log$|,
'new current_logfiles is sane');
like(
$new_current_logfiles,
qr|^stderr log/postgresql-.*log$|,
'new current_logfiles is sane');
$lfname = $new_current_logfiles;
$lfname =~ s/^stderr //;
@@ -82,7 +85,9 @@ for (my $attempts = 0; $attempts < $max_attempts; $attempts++)
usleep(100_000);
}
like($second_logfile, qr/syntax error/,
'found expected log file content in new log file');
like(
$second_logfile,
qr/syntax error/,
'found expected log file content in new log file');
$node->stop();