generated from coulomb/repo-seed
Implement live-shaped readiness workplan
This commit is contained in:
21
tests/test_public_api.py
Normal file
21
tests/test_public_api.py
Normal file
@@ -0,0 +1,21 @@
|
||||
import json
|
||||
from pathlib import Path
|
||||
|
||||
import phase_memory
|
||||
from phase_memory.service import LocalServiceRunner, SERVICE_OPERATIONS, service_contracts
|
||||
|
||||
|
||||
FIXTURES = Path(__file__).parent / "fixtures"
|
||||
|
||||
|
||||
def test_public_api_snapshot_is_explicit() -> None:
|
||||
snapshot = json.loads((FIXTURES / "public-api-snapshot.json").read_text(encoding="utf-8"))
|
||||
|
||||
assert sorted(phase_memory.__all__) == snapshot["exports"]
|
||||
assert sorted(SERVICE_OPERATIONS) == snapshot["service_operations"]
|
||||
|
||||
|
||||
def test_service_contract_catalog_matches_local_runner_supported_operations() -> None:
|
||||
declared = set(service_contracts()["operations"])
|
||||
|
||||
assert set(LocalServiceRunner.supported_operations()) == declared
|
||||
Reference in New Issue
Block a user