Skip to content

Commit 825f3e4

Browse files
committed
add slashes to URL if needed
1 parent 00dd78b commit 825f3e4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

test/test_repository.py

+6-1
Original file line numberDiff line numberDiff line change
@@ -519,7 +519,12 @@ def test_clone_bare_repository(self):
519519
def test_clone_repository_and_remote_callbacks(self):
520520
src_repo_relpath = "./test/data/testrepo.git/"
521521
repo_path = os.path.join(self._temp_dir, "clone-into")
522-
url = 'file:' + pathname2url(os.path.realpath(src_repo_relpath))
522+
url = pathname2url(os.path.realpath(src_repo_relpath))
523+
524+
if url.startswith('///'):
525+
url = 'file:' + url
526+
else:
527+
url = 'file://' + url
523528

524529
def create_repository(path, bare):
525530
return init_repository(path, bare)

0 commit comments

Comments
 (0)