hooks/test_backup_metadata: no need to check metadata if node does not have bundle:backup-client
All checks were successful
bundlewrap/pipeline/head This commit looks good

This commit is contained in:
Franzi 2021-02-18 15:21:27 +01:00
parent 1abc0153f5
commit dba7beae1c
Signed by: kunsi
GPG key ID: 12E3D2136B818350

View file

@ -1,8 +1,8 @@
def test_node(repo, node, **kwargs):
if not node.has_bundle('backup-client'):
return
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!'