process: enforce issue-status consistency in audit doc validation (#390)
This commit is contained in:
@@ -79,3 +79,31 @@ def test_validate_links_avoids_duplicate_error_for_invalid_plan_link(tmp_path) -
|
||||
|
||||
assert len(errors) == 1
|
||||
assert "invalid plan link path" in errors[0]
|
||||
|
||||
|
||||
def test_validate_issue_status_consistency_reports_conflicts() -> None:
|
||||
module = _load_module()
|
||||
errors: list[str] = []
|
||||
path = Path("docs/ouroboros/80_implementation_audit.md").resolve()
|
||||
text = "\n".join(
|
||||
[
|
||||
"| REQ-V3-004 | 상태 | 부분 | `#328` 추적 |",
|
||||
"| 항목 | 상태 | ✅ 완료 | `#328` 머지 |",
|
||||
]
|
||||
)
|
||||
|
||||
module.validate_issue_status_consistency(path, text, errors)
|
||||
|
||||
assert len(errors) == 1
|
||||
assert "conflicting status for issue #328" in errors[0]
|
||||
|
||||
|
||||
def test_validate_issue_status_consistency_allows_done_only() -> None:
|
||||
module = _load_module()
|
||||
errors: list[str] = []
|
||||
path = Path("docs/ouroboros/80_implementation_audit.md").resolve()
|
||||
text = "| 항목 | 상태 | ✅ 완료 | `#371` 머지 |"
|
||||
|
||||
module.validate_issue_status_consistency(path, text, errors)
|
||||
|
||||
assert errors == []
|
||||
|
||||
Reference in New Issue
Block a user