mirror of
https://github.com/outbackdingo/patroni.git
synced 2026-08-25 14:53:37 +00:00
Automatically skip some behave tests on legacy Postgres (#2358)
previously behave had to be started with `--tags=-skip` argument.
This commit is contained in:
@@ -903,3 +903,11 @@ def after_feature(context, feature):
|
||||
context.dcs_ctl.cleanup_service_tree()
|
||||
if feature.status == 'failed':
|
||||
shutil.copytree(context.pctl.output_dir, context.pctl.output_dir + '_failed')
|
||||
|
||||
|
||||
def before_scenario(context, scenario):
|
||||
if 'slot-advance' in scenario.effective_tags:
|
||||
for p in context.pctl._processes.values():
|
||||
if p._conn and p._conn.server_version < 110000:
|
||||
scenario.skip('pg_replication_slot_advance() is not supported on {0}'.format(p._conn.server_version))
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user