Skip to content

Commit 51dfe85

Browse files
committed
refactor(sync tests): Use libvcs pytest plugin's fixture
1 parent b9c0aa1 commit 51dfe85

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

tests/test_sync.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
import kaptan
88

99
from libvcs._internal.shortcuts import create_project
10+
from libvcs.pytest_plugin import CreateProjectCallbackFixtureProtocol
1011
from libvcs.sync.git import GitRemote, GitSync
11-
from tests.conftest import DummyRepoProtocol
1212
from vcspull.cli.sync import update_repo
1313
from vcspull.config import extract_repos, filter_repos, load_configs
1414
from vcspull.types import ConfigDict
@@ -88,14 +88,14 @@ def write_config_remote(
8888
)
8989
def test_config_variations(
9090
tmp_path: pathlib.Path,
91-
create_git_dummy_repo: DummyRepoProtocol,
91+
create_git_remote_repo: CreateProjectCallbackFixtureProtocol,
9292
config_tpl: str,
9393
capsys: pytest.CaptureFixture[str],
9494
remote_list: t.List[str],
9595
) -> None:
9696
"""Test config output with variation of config formats"""
9797
dummy_repo_name = "dummy_repo"
98-
dummy_repo = create_git_dummy_repo(dummy_repo_name)
98+
dummy_repo = create_git_remote_repo(remote_repo_name=dummy_repo_name)
9999

100100
config_file = write_config_remote(
101101
config_path=tmp_path / "myrepos.yaml",
@@ -157,17 +157,17 @@ def test_config_variations(
157157
)
158158
def test_updating_remote(
159159
tmp_path: pathlib.Path,
160-
create_git_dummy_repo: DummyRepoProtocol,
160+
create_git_remote_repo: CreateProjectCallbackFixtureProtocol,
161161
config_tpl: str,
162162
has_extra_remotes: bool,
163163
) -> None:
164164
"""Ensure additions/changes to yaml config are reflected"""
165165

166166
dummy_repo_name = "dummy_repo"
167-
dummy_repo = create_git_dummy_repo(dummy_repo_name)
167+
dummy_repo = create_git_remote_repo(remote_repo_name=dummy_repo_name)
168168

169169
mirror_name = "mirror_repo"
170-
mirror_repo = create_git_dummy_repo(mirror_name)
170+
mirror_repo = create_git_remote_repo(remote_repo_name=mirror_name)
171171

172172
repo_parent = tmp_path / "study" / "myrepo"
173173
repo_parent.mkdir(parents=True)

0 commit comments

Comments
 (0)