This document is the single-source authoritative contract for Test Attachment in ShieldCraft verification (TAC v1). It defines the minimal, non-negotiable requirements that must be satisfied for a checklist item to be considered covered by tests.
Contract rules (exact semantics):
test_refsMUST be present on every checklist item.test_refsMUST be an array of strings.test_refsMUST have length >= 1 (non-empty array).- Each entry in
test_refsMUST be a string identifier referencing a discovered test in the test registry.
Failure behavior:
- Violation of TAC MUST be classified as
PRODUCT_INVARIANT_FAILURE. - The verification gate
tests_attachedMUST fail deterministically with error codetests_attachedand include the list of offending checklist item ids. - TAC enforcement is mandatory before any instruction emission (pre-execution block). Do not proceed on TAC failure.
Notes:
- This contract enforces traceability from checklist items to executable tests; it does not prescribe test content or adequacy — only that a concrete test reference exists and is syntactically valid.