feat(scada): add calibrated monitoring and incident recovery

This commit is contained in:
2026-11-07 19:44:58 +08:00
parent 26fa5d1909
commit ff8aba4964
109 changed files with 9165 additions and 629 deletions
+3 -1
View File
@@ -255,7 +255,7 @@ async def test_created_work_order_receipt_preserves_projection_and_routes_active
"title": "采样工单", "priority": "normal",
"work_order_type": "general", "created_at": "2026-09-23T08:00:00Z",
"scheduled_at": None,
"activity": ([{"sequence": 2, "occurred_at": "2026-09-23T09:00:00Z", "actor": "现场人员",
"activity": ([{"sequence": 2, "occurred_at": "2026-09-23T08:45:00Z", "actor": "现场人员",
"kind": "feedback", "title": "现场反馈", "detail": "复测余氯0.2mg/L"}]
if order_revision > 1 else []),
}
@@ -271,6 +271,8 @@ async def test_created_work_order_receipt_preserves_projection_and_routes_active
assert ("work_order_snapshot" in payload) == request.url.path.endswith(f"{projection_id}/external-feedback")
if order_revision > 1:
assert "复测余氯0.2mg/L" in payload["evidence"]["summary"]
assert payload["occurred_at"] == "2026-09-23T08:45:00Z"
assert payload["evidence"]["observed_at"] == "2026-09-23T08:45:00Z"
return httpx.Response(200, json={})
if request.url.path.endswith(investigation_id):
return httpx.Response(200, json={"actions": [{"kind": "create_work_order", "receipt": {