summaryrefslogtreecommitdiff
path: root/tests/testutils/artifactshare.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testutils/artifactshare.py')
-rw-r--r--tests/testutils/artifactshare.py23
1 files changed, 5 insertions, 18 deletions
diff --git a/tests/testutils/artifactshare.py b/tests/testutils/artifactshare.py
index 39cc7da10..2038bfedd 100644
--- a/tests/testutils/artifactshare.py
+++ b/tests/testutils/artifactshare.py
@@ -80,12 +80,7 @@ class ArtifactShare:
cleanup_on_sigterm()
server = stack.enter_context(
- create_server(
- self.repodir,
- quota=self.quota,
- enable_push=True,
- index_only=self.index_only,
- )
+ create_server(self.repodir, quota=self.quota, enable_push=True, index_only=self.index_only,)
)
port = server.add_insecure_port("localhost:0")
server.start()
@@ -133,9 +128,7 @@ class ArtifactShare:
reachable = set()
def reachable_dir(digest):
- self.cas._reachable_refs_dir(
- reachable, digest, update_mtime=False, check_exists=True
- )
+ self.cas._reachable_refs_dir(reachable, digest, update_mtime=False, check_exists=True)
try:
if str(artifact_proto.files):
@@ -219,13 +212,9 @@ statvfs_result = namedtuple("statvfs_result", "f_blocks f_bfree f_bsize f_bavail
# Assert that a given artifact is in the share
#
def assert_shared(cli, share, project, element_name, *, project_name="test"):
- if not share.get_artifact(
- cli.get_artifact_name(project, project_name, element_name)
- ):
+ if not share.get_artifact(cli.get_artifact_name(project, project_name, element_name)):
raise AssertionError(
- "Artifact share at {} does not contain the expected element {}".format(
- share.repo, element_name
- )
+ "Artifact share at {} does not contain the expected element {}".format(share.repo, element_name)
)
@@ -234,7 +223,5 @@ def assert_shared(cli, share, project, element_name, *, project_name="test"):
def assert_not_shared(cli, share, project, element_name, *, project_name="test"):
if share.get_artifact(cli.get_artifact_name(project, project_name, element_name)):
raise AssertionError(
- "Artifact share at {} unexpectedly contains the element {}".format(
- share.repo, element_name
- )
+ "Artifact share at {} unexpectedly contains the element {}".format(share.repo, element_name)
)