bundles/backup-server: dummy nodes never do backups
Some checks failed
bundlewrap/pipeline/head There was a failure building this commit

This commit is contained in:
Franzi 2020-11-13 21:56:15 +01:00
parent 42133b92de
commit e515378497
Signed by: kunsi
GPG key ID: 12E3D2136B818350
2 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,8 @@
def test_node(repo, node, **kwargs):
if not node.metadata.get('backups', {}).get('exclude_from_backups', False):
assert len(node.metadata.get('backups', {}).get('paths', set())) > 0, f'{node.name} has backups configured, but no backup paths defined!'
if node.metadata.get('backups', {}).get('exclude_from_backups', False):
return
if node.dummy:
return
assert len(node.metadata.get('backups', {}).get('paths', set())) > 0, f'{node.name} has backups configured, but no backup paths defined!'