A-SW Hub / Repositories
Local Gitea · READ ONLY
← 저장소 Repositories
REPOSITORY

kitech/mil-hil-validation Private

[참조 MVP] MIL/HIL 검증 하네스 — 구성요소별 시험 시나리오의 허용오차를 판정하고 감사 가능한 요약을 만듭니다.

https://git.agrithing.ai/kitech/mil-hil-validation.git
8 commits
2 items · main
·/ asw_component/component.py
python · 597 B · 82f1104 Download
from __future__ import annotationsdef execute(payload: dict) -> dict:    results = []    for case in payload.get("scenarios", []):        error = abs(float(case["actual"]) - float(case["expected"]))        passed = error <= float(case.get("tolerance", 0))        results.append({"id": case["id"], "passed": passed, "error": round(error, 6), "evidence": case.get("evidence")})    passed_count = sum(item["passed"] for item in results)    return {"verdict": "PASS" if results and passed_count == len(results) else "FAIL", "passed": passed_count, "total": len(results), "results": results}