Skip to content

The agent that grows with you

test(bundle): verify seeded venv state

Yuan Lifc1c8bc25aee
diff --git a/tests/scripts/test_bundle_native.py b/tests/scripts/test_bundle_native.py
index 2245c3fd103..bbaf0d1d99f 100644
--- a/tests/scripts/test_bundle_native.py
+++ b/tests/scripts/test_bundle_native.py
@@ -19,6 +19,7 @@ import pytest
from scripts.bundles import native
[email protected](sys.platform == "darwin", reason="native Python fixture contains unavailable framework header links on macOS")
def test_bundle_stages_git_tree_and_runs_native_children_before_manifest(tmp_path, monkeypatch):
import importlib
import inspect
@@ -254,6 +255,10 @@ def test_bundle_stages_git_tree_and_runs_native_children_before_manifest(tmp_pat
assert venv_fact is not None
assert venv_fact["extras"] == json.loads((output / "enabled-features.json").read_text())
assert "environment" not in venv_fact
+ from pm.install import venv_is_current
+ with monkeypatch.context() as patch:
+ patch.setattr("pm.paths.repo_root", lambda: output / "hermes-agent")
+ assert venv_is_current(project_root=output / "hermes-agent")
for name in stale:
assert facts.get(name) is None
assert not (output / "tools" / f"cached-{name}").exists()