feat(deploy): register Engine telemetry catalog transition

This commit is contained in:
Codex
2026-07-23 14:55:56 +03:00
parent e4383b6162
commit f97a9d924d
4 changed files with 865 additions and 0 deletions
@@ -147,6 +147,35 @@ class EngineNodeIntelligenceTest(unittest.TestCase):
)
self.assertEqual(actual, descriptor)
def test_gateway_accepts_registered_0_8_and_rejects_unknown_successors(self):
with tempfile.TemporaryDirectory() as directory:
payload, descriptor = self.make_activation_payload(Path(directory))
gateway = payload / RUNNER.ENGINE_NODE_INTELLIGENCE_GATEWAY_REL
gateway_text = gateway.read_text(encoding="utf-8")
self.assertIn("const ENGINE_AGENT_MCP_VERSION = '0.8.0'", gateway_text)
gateway.write_text(
gateway_text.replace(
"const ENGINE_AGENT_MCP_VERSION = '0.8.0'",
"const ENGINE_AGENT_MCP_VERSION = '9.9.9'",
),
encoding="utf-8",
)
descriptor["source"]["gatewaySha256"] = sha256(gateway)
(
payload / RUNNER.ENGINE_NODE_INTELLIGENCE_DESCRIPTOR_REL
).write_text(
json.dumps(descriptor, indent=2) + "\n",
encoding="utf-8",
)
with self.assertRaisesRegex(
RUNNER.DeployError,
"gateway MCP version is not registered",
):
RUNNER.validate_engine_node_intelligence_transition(
payload,
RUNNER.ENGINE_NODE_INTELLIGENCE_ARTIFACT_ENTRIES,
)
def test_archive_tamper_and_embedded_authority_fail_closed(self):
with tempfile.TemporaryDirectory() as directory:
root = Path(directory)