scrum4me-mcp/__tests__
Janpeter Visser 1fe6ccf609
feat(gate): verify_required levels — ALIGNED/ALIGNED_OR_PARTIAL/ANY (#16)
Sluit story 'Verify-gate uitbreiden' in PBI 'Agent verify-flow hardening' af.

The previous gate weighed only EMPTY: any PARTIAL or DIVERGENT verify
slipped through. The Insights batch (2 May 2026) showed why that's
weak — agent-jobs claiming DONE while only delivering helpers, not
the requested UI components, with verify=DIVERGENT/PARTIAL accepted.

New decision matrix:

  null                       → reject (run verify_task_against_plan)
  EMPTY  + !verify_only      → reject
  EMPTY  + verify_only       → allowed
  ALIGNED                    → always allowed
  PARTIAL/DIVERGENT
    required=ALIGNED         → reject (strict task)
    required=ALIGNED_OR_PARTIAL (default) → allowed only if summary
                                            ≥20 chars (acknowledge drift)
    required=ANY             → allowed (refactor escape hatch)

`update_job_status('done')` now reads `task.verify_required` from the DB
(field added in Scrum4Me PR #53) and passes it + `summary` to the gate.
Tool description updated with the new rules.

Vendor submodule synced to pick up the schema enum.

Tests: 129/129 (was 120 + 9 new combinatorial gate tests).

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-02 17:55:06 +02:00
..
git feat(M13): auto-PR via gh CLI after successful push (auto_pr=true) 2026-05-01 13:30:38 +02:00
verify feat: classifyDiffAgainstPlan — pure diff vs plan classifier (VerifyResult) 2026-05-01 12:55:47 +02:00
cleanup-my-worktrees.test.ts feat(M13): cleanup_my_worktrees tool — scan + remove stale worktrees for terminal-status jobs 2026-05-01 13:22:47 +02:00
get-claude-context-filter.test.ts test: add unit tests for tasks-status-update helper and get-claude-context filter 2026-04-30 18:22:55 +02:00
tasks-status-update.test.ts test: add unit tests for tasks-status-update helper and get-claude-context filter 2026-04-30 18:22:55 +02:00
update-job-status-auto-pr.test.ts feat: branch-per-story + worktree-defer + verify EMPTY edge-cases (#12) 2026-05-01 17:04:54 +02:00
update-job-status-gate.test.ts feat(gate): verify_required levels — ALIGNED/ALIGNED_OR_PARTIAL/ANY (#16) 2026-05-02 17:55:06 +02:00
update-job-status-next-action.test.ts feat: worker presence layer + batch-loop docs (#7) 2026-05-01 16:39:26 +02:00
update-job-status-push.test.ts feat: integrate push into update_job_status DONE transition 2026-05-01 12:00:30 +02:00
update-job-status-worktree.test.ts feat: branch-per-story + worktree-defer + verify EMPTY edge-cases (#12) 2026-05-01 17:04:54 +02:00
verify-plan.test.ts test+docs: verify-plan tests and README for verify_task_against_plan 2026-04-30 19:36:43 +02:00
verify-task-against-plan.test.ts feat: verify_task_against_plan calls classifyDiffAgainstPlan + saves verify_result to DB 2026-05-01 12:59:17 +02:00
wait-for-job-snapshot.test.ts feat(M13): retry-tracking — stale CLAIMED jobs → QUEUED (retry_count++) or FAILED (≥2 retries) 2026-05-01 13:18:59 +02:00
wait-for-job-worktree.test.ts feat: branch-per-story + worktree-defer + verify EMPTY edge-cases (#12) 2026-05-01 17:04:54 +02:00