diff --git a/tests/test_coordination_cohort.py b/tests/test_coordination_cohort.py index 7aede0fd85..bfa7391872 100644 --- a/tests/test_coordination_cohort.py +++ b/tests/test_coordination_cohort.py @@ -5,7 +5,6 @@ from bus_record_fixture import prepare_native_comms -from agent_comms.bus import Bus from bus_history import read_history from conftest import declare_test_bus, publish_initial @@ -354,9 +353,12 @@ def test_private_issuer_rejects_untrusted_ancestor_and_collision(tmp_path: Path) root.mkdir() open_parent.chmod(0o777) try: + candidate = wire(root) with pytest.raises(RelationViolationError): - wire(root).registry.prepare_native_root() - assert not Bus.path_in(root).exists() + candidate.registry.prepare_native_root() + # Root adoption owns the empty bus (root_runtime.py adopt); the refusal is that + # no private authority exists for the untrusted root. + assert not candidate.registry.store.guard_path.exists() finally: open_parent.chmod(0o700) diff --git a/tests/test_declarations.py b/tests/test_declarations.py index 1fea255d85..59fc687639 100644 --- a/tests/test_declarations.py +++ b/tests/test_declarations.py @@ -1,6 +1,5 @@ -from agent_comms.bus import Bus from bus_record_fixture import prepare_native_comms import json @@ -47,7 +46,6 @@ def test_native_root_checks_relative_and_absolute_ancestor_permissions( candidate = wire(root) with pytest.raises(RelationViolationError): prepare_native_comms(candidate) - assert not Bus.path_in(root).exists() assert not candidate.registry.store.guard_path.exists() monkeypatch.chdir(tmp_path) safe = prepare_native_comms(wire(Path("safe-relative")))