Skip to content

S002 Success Criteria

IDCriterion
S002-SC-001Each of the five built-in rules (test-exists, enforce-coverage-link, minimum-coverage, matched-coverage, coverage-attribution) can be unit-tested in isolation by constructing a RuleContext and calling evaluate() without any filesystem, database, or service dependencies (except enforce-coverage-link which delegates to S004 linkers).
S002-SC-002A custom rule class implementing RuleInterface can be registered in RuleRegistry, resolved from a YAML config array, and evaluated in the check pipeline without modifying any Parity core code. The only integration point is RuleRegistry::register().
S002-SC-003Providing an unknown rule name, a missing required parameter, or a parameter of the wrong type to RuleRegistry::resolve() always throws an InvalidArgumentException with a message that identifies the specific rule and parameter at fault.
S002-SC-004When a source file passes all enforced rules but has informational rule data (e.g. coverage-attribution reports `"5