Skip to content

Commit f0864a2

Browse files
committed
tests: replica slow_start() minor change
1 parent dddf885 commit f0864a2

File tree

3 files changed

+17
-9
lines changed

3 files changed

+17
-9
lines changed

tests/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@ def load_tests(loader, tests, pattern):
6060
# ptrack backup on replica should work correctly
6161
# archive:
6262
# immediate recovery and full recovery
63+
# backward compatibility:
64+
# previous version catalog must be readable by newer version
65+
# incremental chain from previous version can be continued
66+
# backups from previous version can be restored
6367
# 10vanilla_1.3ptrack +
6468
# 10vanilla+
6569
# 9.6vanilla_1.3ptrack +

tests/helpers/ptrack_helpers.py

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -131,14 +131,18 @@ def slow_start(self, replica=False):
131131
except Exception as e:
132132
continue
133133
else:
134-
while True:
135-
try:
136-
self.poll_query_until(
137-
"postgres",
138-
"SELECT pg_is_in_recovery()")
139-
break
140-
except Exception as e:
141-
continue
134+
self.poll_query_until(
135+
"postgres",
136+
"SELECT pg_is_in_recovery()")
137+
138+
# while True:
139+
# try:
140+
# self.poll_query_until(
141+
# "postgres",
142+
# "SELECT pg_is_in_recovery()")
143+
# break
144+
# except ProbackupException as e:
145+
# continue
142146

143147

144148
class ProbackupTest(object):

tests/replica.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ def test_make_replica_via_restore(self):
287287
self.set_archiving(backup_dir, 'replica', replica, replica=True)
288288
replica.append_conf(
289289
'postgresql.auto.conf', 'port = {0}'.format(replica.port))
290-
replica.slow_start(replica=True)
290+
replica.start()
291291

292292
# Clean after yourself
293293
self.del_test_dir(module_name, fname)

0 commit comments

Comments
 (0)