fix(compat-fallout): dashboard tests patch defining modules (main_web_build._build_web_ui, web_routers.skills._installed_hub_identifiers)

This commit is contained in:
Teknium
2026-09-03 15:56:38 -07:00
parent e6bfbf82fa
commit 830b82bd03
2 changed files with 3 additions and 3 deletions
@@ -681,7 +681,7 @@ class TestOfficialSkillsCatalogEndpoint:
lambda self: metas,
)
monkeypatch.setattr(
"hermes_cli.web_server_profiles._installed_hub_identifiers",
"hermes_cli.web_routers.skills._installed_hub_identifiers",
lambda profile=None: {"official/gifs/gif-search": {"name": "gif-search"}},
)
r = self.client.get("/api/skills/hub/official")
@@ -74,7 +74,7 @@ def test_env_dist_without_index_exits(main_mod, monkeypatch, tmp_path, capsys):
)
builds = []
monkeypatch.setattr(
main_mod, "_build_web_ui", lambda *a, **k: builds.append(a) or True
"hermes_cli.main_web_build._build_web_ui", lambda *a, **k: builds.append(a) or True
)
with pytest.raises(SystemExit) as exc:
@@ -122,7 +122,7 @@ def test_skip_build_missing_dist_attempts_one_recovery_build(
(dist / "index.html").write_text("<html></html>", encoding="utf-8")
return True
monkeypatch.setattr(main_mod, "_build_web_ui", fake_build)
monkeypatch.setattr("hermes_cli.main_web_build._build_web_ui", fake_build)
main_mod.cmd_dashboard(_args(skip_build=True))