Add a wait_for_catchup() before immediate stop of a test master.

Per buildfarm member hoverfly, a slow walsender could make the test
fail.  Back-patch to v10, where the test was introduced.

Discussion: https://postgr.es/m/20200414013849.GA886648@rfd.leadboat.com
This commit is contained in:
Noah Misch 2020-04-13 18:47:28 -07:00
parent e56d717d8a
commit d60cfb6bf2
1 changed files with 1 additions and 0 deletions

View File

@ -131,6 +131,7 @@ cmp_ok(
'xmin on physical slot must not be lower than catalog_xmin');
$node_master->safe_psql('postgres', 'CHECKPOINT');
$node_master->wait_for_catchup($node_replica, 'write');
# Boom, crash
$node_master->stop('immediate');