summaryrefslogtreecommitdiff
path: root/tests/base.py
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2022-05-30 15:56:23 +0000
committerGerrit Code Review <review@openstack.org>2022-05-30 15:56:23 +0000
commit64b80001ee72460a8ca589e350cf298b78c17aea (patch)
tree5fdd85a0c47c38d1ef395421660cf805db9dbbb9 /tests/base.py
parentc44a86edde7048c6fd9aeafa1823391e89dc2968 (diff)
parentc41fcbe483529deffb345808fdb489ff81de7d3c (diff)
downloadzuul-64b80001ee72460a8ca589e350cf298b78c17aea.tar.gz
Merge "Add support for GHE repository cache"
Diffstat (limited to 'tests/base.py')
-rw-r--r--tests/base.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/base.py b/tests/base.py
index 55be849dc..4d99ab00d 100644
--- a/tests/base.py
+++ b/tests/base.py
@@ -333,11 +333,9 @@ class GitlabDriverMock(GitlabDriver):
class TestConnectionRegistry(ConnectionRegistry):
- def __init__(self, changes: Dict[str, Dict[str, Change]],
- config: ConfigParser, additional_event_queues,
- upstream_root: str, poller_events,
- git_url_with_auth: bool,
- add_cleanup: Callable[[Callable[[], None]], None]):
+ def __init__(self, changes, config, additional_event_queues,
+ upstream_root, poller_events, git_url_with_auth,
+ add_cleanup):
self.connections = OrderedDict()
self.drivers = {}
@@ -2953,6 +2951,8 @@ class FakeGithubConnection(githubconnection.GithubConnection):
prefix = 'file://x-access-token:%s@' % auth_token
else:
prefix = ''
+ if self.repo_cache:
+ return prefix + os.path.join(self.repo_cache, str(project))
return prefix + os.path.join(self.upstream_root, str(project))
def real_getGitUrl(self, project):