Skip to content

test(foreman): lock in sliced-workload verdict rollup#1048

Merged
Defilan merged 1 commit into
defilantech:mainfrom
Defilan:feat/slicer-rollup-lockin
Jul 10, 2026
Merged

test(foreman): lock in sliced-workload verdict rollup#1048
Defilan merged 1 commit into
defilantech:mainfrom
Defilan:feat/slicer-rollup-lockin

Conversation

@Defilan

@Defilan Defilan commented Jul 10, 2026

Copy link
Copy Markdown
Member

What

Task 5 of the Sliced Workloads epic (#1033): confirm and lock in that a sliced Workload's integrate and reconcile steps roll up to the Workload correctly.

No production wiring is needed. classifyChildren is verdict-based, not kind-based, so a Succeeded + GATE-FAIL reconcile (pinned interface drift) or integrate (overlap / stale-base apply) already lands in the incomplete bucket — which keeps the Workload out of Completed — while a clean GATE-PASS counts as succeeded. Same mechanism as the existing verify/reviewer GATE-FAIL rollup (#541/#548).

Why

The epic listed a "controller rollup" task assuming new wiring. On inspection the #548 rollup already does the right thing for the new kinds; this PR makes that a tested, documented guarantee rather than an accident.

How

  • A classifyChildren unit test over {integrate, reconcile} x {GATE-PASS, GATE-FAIL}, asserting the clean verdicts count as succeeded and the failing ones as incomplete. If a future change special-cases kinds in classifyChildren, this fails.
  • A doc note on classifyChildren recording that the slicer kinds deliberately ride this kind-agnostic classification.

Deferred (with llm_sweep): the llm-flagged-advisory annotation on the Workload — that arrives when the LLM sweep is wired into run_reconcile.

Testing

go test ./internal/foreman/controller/ -run TestClassifyChildren_SlicerVerdicts — 4/4 subtests pass. Build + golangci-lint clean.

Checklist

  • Unit test locks in the new kinds' rollup
  • No production behavior change (verdict-based rollup already covers it)
  • DCO sign-off

Part of #1033


Assisted-by: Claude Code (Opus 4.8); reviewed and verified by the author.

Task 5 of the Sliced Workloads epic (defilantech#1033): confirm a sliced Workload's
integrate/reconcile steps roll up to the Workload correctly. No production
wiring is needed: classifyChildren is verdict-based, not kind-based, so a
Succeeded + GATE-FAIL reconcile (pinned interface drift) or integrate (overlap /
stale-base apply) already lands in the incomplete bucket and keeps the Workload
out of Completed, while a clean GATE-PASS counts as succeeded.

Adds a classifyChildren unit test over the integrate/reconcile kinds x
GATE-PASS/GATE-FAIL so a future kind-special-casing change can't silently
regress the slicer's reliance on this, plus a doc note recording it.

Part of defilantech#1033

Signed-off-by: Christopher Maher <chris@mahercode.io>
@codecov

codecov Bot commented Jul 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@Defilan Defilan merged commit a80ac00 into defilantech:main Jul 10, 2026
24 of 25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant