Browse Source

tests: fix for non-unique archive names

For Archive(), always use the archive id, not the archive name!
Thomas Waldmann 8 months ago
parent
commit
eb75390240
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/borg/testsuite/archiver/__init__.py

+ 2 - 1
src/borg/testsuite/archiver/__init__.py

@@ -169,7 +169,8 @@ def open_archive(repo_path, name):
     repository = Repository(repo_path, exclusive=True)
     with repository:
         manifest = Manifest.load(repository, Manifest.NO_OPERATION_CHECK)
-        archive = Archive(manifest, name)
+        archive_info = manifest.archives.get_one(name)
+        archive = Archive(manifest, archive_info.id)
     return archive, repository