aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2024-01-11 15:01:51 -0500
committerRobert Haas <rhaas@postgresql.org>2024-01-11 15:01:51 -0500
commita7097ca630a25dd2248229f21ebce4968d85d10a (patch)
treeb98fd6458aa628a394f903edbb7dae595c1fdf80
parente2d5b3b9b643739bd83e42769b44005dfd2bbb90 (diff)
downloadpostgresql-a7097ca630a25dd2248229f21ebce4968d85d10a.tar.gz
postgresql-a7097ca630a25dd2248229f21ebce4968d85d10a.zip
Try to fix pg_walsummary buildfarm failures.
Apparently the new tuple isn't guaranteed to end up at the end of the relation, so make the test not depend on that happening.
-rw-r--r--src/bin/pg_walsummary/t/002_blocks.pl8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/bin/pg_walsummary/t/002_blocks.pl b/src/bin/pg_walsummary/t/002_blocks.pl
index 170976f9e2d..d473471bc7e 100644
--- a/src/bin/pg_walsummary/t/002_blocks.pl
+++ b/src/bin/pg_walsummary/t/002_blocks.pl
@@ -78,10 +78,10 @@ my $filename = sprintf "%s/pg_wal/summaries/%08s%08s%08s%08s%08s.summary",
split(m@/@, $end_lsn);
ok(-f $filename, "WAL summary file exists");
-# Run pg_walsummary on it. We expect block 0 to be modified, but block 1
-# to be unmodified, so the output should say block 0, not block 0..1 or
-# similar.
-my ($stdout, $stderr) = run_command([ 'pg_walsummary', $filename ]);
+# Run pg_walsummary on it. We expect block 0 to be modified, but depending
+# on where the new tuple ends up, block 1 might also be modified, so we
+# pass -i to pg_walsummary to make sure we don't end up with a 0..1 range.
+my ($stdout, $stderr) = run_command([ 'pg_walsummary', '-i', $filename ]);
like($stdout, qr/FORK main: block 0$/m, "stdout shows block 0 modified");
is($stderr, '', 'stderr is empty');