Skip to content

Commit 2f30477

Browse files
committed
Revert SHARED_REPO_NAME to avoid string duplication
1 parent c7e1a64 commit 2f30477

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

tmt/steps/prepare/artifact/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
from tmt.steps.prepare import PreparePlugin, PrepareStepData
1414
from tmt.steps.prepare.artifact.providers import (
1515
_PROVIDER_REGISTRY,
16+
SHARED_REPO_NAME,
1617
ArtifactProvider,
1718
Repository,
1819
)
@@ -31,9 +32,6 @@
3132
from tmt.utils import Path
3233
from tmt.utils.environment import Environment
3334

34-
#: Name of the shared repository that download providers contribute RPMs into.
35-
SHARED_REPO_NAME: str = 'tmt-artifact-shared'
36-
3735

3836
@container
3937
class PrepareArtifactData(PrepareStepData):

tmt/steps/prepare/artifact/providers/__init__.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@
2727
r'^(?P<name>.+)-(?:(?P<epoch>\d+):)?(?P<version>.+)-(?P<release>.+)\.(?P<arch>.+)$'
2828
)
2929

30+
#: Name of the shared repository that download providers contribute RPMs into.
31+
SHARED_REPO_NAME: str = 'tmt-artifact-shared'
32+
3033

3134
class UnsupportedOperationError(RuntimeError):
3235
"""
@@ -45,7 +48,7 @@ class ArtifactInfo:
4548
provider: "ArtifactProvider"
4649
#: Repository ID this artifact is available from. Used during verification
4750
#: to confirm the artifact was installed from the expected repository.
48-
repo_id: str = 'tmt-artifact-shared'
51+
repo_id: str = SHARED_REPO_NAME
4952

5053
@property
5154
def id(self) -> str:

0 commit comments

Comments
 (0)