Skip to content

Commit a9d2ce4

Browse files
committed
Set install_dir on test config
1 parent c7d5b43 commit a9d2ce4

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

tests/conftest.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -152,11 +152,11 @@ def localserver():
152152

153153

154154
class FakeConfig:
155-
def __init__(self, global_dir, installs=[]):
156-
self.global_dir = global_dir
157-
self.root = global_dir.parent if global_dir else None
158-
self.download_dir = self.root / "_cache" if self.root else None
159-
self.start_folder = self.root / "_start" if self.root else None
155+
def __init__(self, root, installs=[]):
156+
self.root = self.install_dir = root
157+
self.global_dir = root / "bin" if root else None
158+
self.download_dir = root / "_cache" if root else None
159+
self.start_folder = root / "_start" if root else None
160160
self.pep514_root = REG_TEST_ROOT
161161
self.confirm = False
162162
self.installs = list(installs)
@@ -186,7 +186,7 @@ def ask_yn(self, question):
186186

187187
@pytest.fixture
188188
def fake_config(tmp_path):
189-
return FakeConfig(tmp_path / "bin")
189+
return FakeConfig(tmp_path)
190190

191191

192192
class RegistryFixture:

0 commit comments

Comments
 (0)