test(review): add a cross-order-mode invariant test for the sweep one-shot fix - #4475
Conversation
…-shot fix Adds an INVARIANT test to selectRegateCandidates covering both order modes (staleness, oldest-first) across a multi-sweep drain with a mixed backlog of never-regated, already-regated, and repair-priority PRs, asserting an already-regated non-repair PR never resurfaces on any later pass. Guards against the endless-reregate class of bug silently regressing.
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4475 +/- ##
=======================================
Coverage 94.03% 94.03%
=======================================
Files 420 420
Lines 37521 37521
Branches 13701 13701
=======================================
Hits 35282 35282
Misses 1583 1583
Partials 656 656 🚀 New features to boost your workflow:
|
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-09 21:20:17 UTC
⏸️ Suggested Action - Manual Review
Review summary Nits — 4 non-blocking
Concerns raised — review before merging
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Summary
selectRegateCandidatescovering both order modes (staleness,oldest-first) across a simulated multi-sweep drain with a mixed backlog (never-regated, already-regated, repair-priority PRs), asserting an already-regated non-repair PR never resurfaces on any later sweep.Scope
type(scope): short summaryConventional Commit format.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
npm run typechecknpx vitest run test/unit/agent-sweep.test.ts test/unit/queue.test.ts(791 passed)npm run test:coveragenot re-run locally for this test-only diff;test/**is Codecov-ignored and CI runs the full gate.If any required check was skipped, explain why:
src/**lines changed), socodecov/patchhas nothing to measure; relying on CI for the full gate per house convention for test-only diffs.Safety
Notes
github_app.ai_review_frozen_reuse) instead of spending a fresh call, until a maintainer explicitly retriggers it. No new code needed there.