generated from coulomb/repo-seed
Harden registry API and schema validation
This commit is contained in:
@@ -143,6 +143,8 @@ def test_registry_http_service_serves_queries(tmp_path: Path) -> None:
|
||||
|
||||
with urllib.request.urlopen(f"{base_url}/health", timeout=5) as response:
|
||||
assert json.loads(response.read())["status"] == "ok"
|
||||
with urllib.request.urlopen(f"{base_url}/status", timeout=5) as response:
|
||||
status_payload = json.loads(response.read())
|
||||
with urllib.request.urlopen(
|
||||
f"{base_url}/repositories/railiance-fabric/snapshots",
|
||||
timeout=5,
|
||||
@@ -211,6 +213,8 @@ def test_registry_http_service_serves_queries(tmp_path: Path) -> None:
|
||||
library_projection_payload = json.loads(response.read())
|
||||
assert providers_payload[0]["provider_id"] == "railiance-platform.openbao.runtime-secrets"
|
||||
assert snapshots_payload[0]["commit"] == "test-cli-2"
|
||||
assert status_payload["counts"]["repositories"] == 1
|
||||
assert status_payload["counts"]["snapshots"] == 3
|
||||
assert drift_payload["graph"]["removed_nodes"]
|
||||
assert artifact_payload["name"] == "OpenBao KV API"
|
||||
assert artifacts_payload[0]["artifact_type"] == "openapi"
|
||||
|
||||
Reference in New Issue
Block a user