__init__.py python
24 lines 755 B
Raw
sha256:a78e7e5a8740e03315f325d19edeb3aa1b306b3337d04abbaa9a9e0f3bbeb7a1 docs: MuseHub-first before ISR #74 — staging solidify NEXT Human 1 day ago
1 """Fixture helpers for Track Q / Q3 desktop packaging tests."""
2
3 from __future__ import annotations
4
5 from pathlib import Path
6
7 from tests.fixtures.app import free_port, seed_app_repo
8 from tests.support import KIT_ROOT
9 from tools.desktop.launcher import DesktopLauncher, resolve_kit_root, resolve_repo_root
10
11
12 def make_desktop_launcher(
13 tmp_path: Path,
14 *,
15 port: int | None = None,
16 seed: bool = True,
17 ) -> DesktopLauncher:
18 """Seed a repo and return a launcher bound to an ephemeral port."""
19 if seed:
20 seed_app_repo(tmp_path)
21 chosen = port or free_port()
22 kit = resolve_kit_root(KIT_ROOT)
23 repo = resolve_repo_root(kit=kit, explicit=tmp_path)
24 return DesktopLauncher(kit_root_path=kit, repo_root=repo, port=chosen)
File History 1 commit
sha256:a78e7e5a8740e03315f325d19edeb3aa1b306b3337d04abbaa9a9e0f3bbeb7a1 docs: MuseHub-first before ISR #74 — staging solidify NEXT Human 1 day ago