|
1 | 1 | import pathlib |
2 | 2 | import textwrap |
3 | | -from typing import Callable, List |
| 3 | +import typing as t |
4 | 4 |
|
5 | 5 | import pytest |
6 | 6 |
|
7 | 7 | import kaptan |
8 | 8 |
|
9 | 9 | from libvcs._internal.shortcuts import create_project |
10 | 10 | from libvcs.projects.git import GitProject, GitRemote |
| 11 | +from tests.conftest import DummyRepoProtocol |
11 | 12 | from vcspull.cli.sync import update_repo |
12 | 13 | from vcspull.config import extract_repos, filter_repos, load_configs |
13 | 14 | from vcspull.types import ConfigDict |
@@ -86,11 +87,11 @@ def write_config_remote( |
86 | 87 | ) |
87 | 88 | def test_config_variations( |
88 | 89 | tmp_path: pathlib.Path, |
89 | | - create_git_dummy_repo: Callable[[str], pathlib.Path], |
| 90 | + create_git_dummy_repo: DummyRepoProtocol, |
90 | 91 | config_tpl: str, |
91 | 92 | capsys: pytest.CaptureFixture[str], |
92 | | - remote_list: List[str], |
93 | | -): |
| 93 | + remote_list: t.List[str], |
| 94 | +) -> None: |
94 | 95 | """Test config output with variation of config formats""" |
95 | 96 | dummy_repo_name = "dummy_repo" |
96 | 97 | dummy_repo = create_git_dummy_repo(dummy_repo_name) |
@@ -155,10 +156,10 @@ def test_config_variations( |
155 | 156 | ) |
156 | 157 | def test_updating_remote( |
157 | 158 | tmp_path: pathlib.Path, |
158 | | - create_git_dummy_repo: Callable[[str], pathlib.Path], |
| 159 | + create_git_dummy_repo: DummyRepoProtocol, |
159 | 160 | config_tpl: str, |
160 | | - has_extra_remotes, |
161 | | -): |
| 161 | + has_extra_remotes: bool, |
| 162 | +) -> None: |
162 | 163 | """Ensure additions/changes to yaml config are reflected""" |
163 | 164 |
|
164 | 165 | dummy_repo_name = "dummy_repo" |
|
0 commit comments