Fix broken wait-for-previous-process-to-exit loop in regression test.

Must do pg_stat_clear_snapshot() inside test's loop, or our snapshot of
pg_stat_activity will never change :-(.  Thinko in b3427dade -- evidently
my workstation never really iterated the loop in testing.  Per buildfarm.
This commit is contained in:
Tom Lane 2016-12-02 17:23:54 -05:00
parent 767a9039d7
commit 19fcc0058e
2 changed files with 2 additions and 2 deletions

View File

@ -106,7 +106,7 @@ do 'declare c int = 0;
begin
while (select count(*) from pg_stat_activity where pid = '
:'oldpid'
') > 0 loop c := c + 1; end loop;
') > 0 loop c := c + 1; perform pg_stat_clear_snapshot(); end loop;
raise log ''test_extensions looped % times'', c;
end';
-- extension should now contain no temp objects

View File

@ -55,7 +55,7 @@ do 'declare c int = 0;
begin
while (select count(*) from pg_stat_activity where pid = '
:'oldpid'
') > 0 loop c := c + 1; end loop;
') > 0 loop c := c + 1; perform pg_stat_clear_snapshot(); end loop;
raise log ''test_extensions looped % times'', c;
end';