aboutsummaryrefslogtreecommitdiff
path: root/src/bin/pg_verifybackup/t/007_wal.pl
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/pg_verifybackup/t/007_wal.pl')
-rw-r--r--src/bin/pg_verifybackup/t/007_wal.pl26
1 files changed, 20 insertions, 6 deletions
diff --git a/src/bin/pg_verifybackup/t/007_wal.pl b/src/bin/pg_verifybackup/t/007_wal.pl
index de6ef13d083..babc4f0a86b 100644
--- a/src/bin/pg_verifybackup/t/007_wal.pl
+++ b/src/bin/pg_verifybackup/t/007_wal.pl
@@ -15,7 +15,12 @@ $primary->init(allows_streaming => 1);
$primary->start;
my $backup_path = $primary->backup_dir . '/test_wal';
$primary->command_ok(
- [ 'pg_basebackup', '-D', $backup_path, '--no-sync', '-cfast' ],
+ [
+ 'pg_basebackup',
+ '--pgdata' => $backup_path,
+ '--no-sync',
+ '--checkpoint' => 'fast'
+ ],
"base backup ok");
# Rename pg_wal.
@@ -30,13 +35,17 @@ command_fails_like(
'missing pg_wal causes failure');
# Should work if we skip WAL verification.
-command_ok(
- [ 'pg_verifybackup', '-n', $backup_path ],
+command_ok([ 'pg_verifybackup', '--no-parse-wal', $backup_path ],
'missing pg_wal OK if not verifying WAL');
# Should also work if we specify the correct WAL location.
-command_ok([ 'pg_verifybackup', '-w', $relocated_pg_wal, $backup_path ],
- '-w can be used to specify WAL directory');
+command_ok(
+ [
+ 'pg_verifybackup',
+ '--wal-directory' => $relocated_pg_wal,
+ $backup_path
+ ],
+ '--wal-directory can be used to specify WAL directory');
# Move directory back to original location.
rename($relocated_pg_wal, $original_pg_wal) || die "rename pg_wal back: $!";
@@ -70,7 +79,12 @@ my $backup_path2 = $primary->backup_dir . '/test_tli';
# The base backup run below does a checkpoint, that removes the first segment
# of the current timeline.
$primary->command_ok(
- [ 'pg_basebackup', '-D', $backup_path2, '--no-sync', '-cfast' ],
+ [
+ 'pg_basebackup',
+ '--pgdata' => $backup_path2,
+ '--no-sync',
+ '--checkpoint' => 'fast'
+ ],
"base backup 2 ok");
command_ok(
[ 'pg_verifybackup', $backup_path2 ],