Skip to content

Commit 13e8b2e

Browse files
committed
Further improve stability of partition_prune regression test.
Commits 4ea03f3 et al arranged to filter out row counts in parallel plans, because those are dependent on the number of workers actually obtained. Somehow I missed that the 'Rows Removed by Filter' counts can also vary, so fix that too. Per buildfarm. This seems worth a last-minute patch because unreliable regression tests are a serious pain in the rear for packagers. Like the previous patch, back-patch to v11 where this test was introduced.
1 parent 2cd75e4 commit 13e8b2e

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/test/regress/expected/partition_prune.out

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1908,6 +1908,7 @@ begin
19081908
loop
19091909
ln := regexp_replace(ln, 'Workers Launched: \d+', 'Workers Launched: N');
19101910
ln := regexp_replace(ln, 'actual rows=\d+ loops=\d+', 'actual rows=N loops=N');
1911+
ln := regexp_replace(ln, 'Rows Removed by Filter: \d+', 'Rows Removed by Filter: N');
19111912
return next ln;
19121913
end loop;
19131914
end;
@@ -2148,7 +2149,7 @@ select explain_parallel_append('select avg(ab.a) from ab inner join lprt_a a on
21482149
-> Nested Loop (actual rows=N loops=N)
21492150
-> Parallel Seq Scan on lprt_a a (actual rows=N loops=N)
21502151
Filter: (a = ANY ('{1,0,0}'::integer[]))
2151-
Rows Removed by Filter: 1
2152+
Rows Removed by Filter: N
21522153
-> Append (actual rows=N loops=N)
21532154
-> Index Scan using ab_a1_b1_a_idx on ab_a1_b1 (actual rows=N loops=N)
21542155
Index Cond: (a = a.a)
@@ -2182,7 +2183,7 @@ select explain_parallel_append('select avg(ab.a) from ab inner join lprt_a a on
21822183
-> Nested Loop (actual rows=N loops=N)
21832184
-> Parallel Seq Scan on lprt_a a (actual rows=N loops=N)
21842185
Filter: (a = ANY ('{1,0,0}'::integer[]))
2185-
Rows Removed by Filter: 1
2186+
Rows Removed by Filter: N
21862187
-> Append (actual rows=N loops=N)
21872188
-> Index Scan using ab_a1_b1_a_idx on ab_a1_b1 (never executed)
21882189
Index Cond: (a = a.a)

src/test/regress/sql/partition_prune.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,7 @@ begin
447447
loop
448448
ln := regexp_replace(ln, 'Workers Launched: \d+', 'Workers Launched: N');
449449
ln := regexp_replace(ln, 'actual rows=\d+ loops=\d+', 'actual rows=N loops=N');
450+
ln := regexp_replace(ln, 'Rows Removed by Filter: \d+', 'Rows Removed by Filter: N');
450451
return next ln;
451452
end loop;
452453
end;

0 commit comments

Comments
 (0)