shankar0123
15fedbaa06
test(scheduler): SCALE-001 — assert claim cap via non-Pending count, not Running
...
Sprint 2's TestProcessPendingJobs_RespectsClaimLimit asserted
that exactly 3 jobs sat in JobStatusRunning after a 10-row
ProcessPendingJobs sweep with SetClaimLimit(3). The CI run
landed 'running-job count = 0; want 3.'
Root cause: the mock's ClaimPendingJobs flips Pending → Running
on the 3 claimed rows (atomic-claim semantics). processJob then
calls renewalService.ProcessRenewalJob, which fails on the
mock cert-repo's not-found error and calls failJob → which
transitions the row from Running → Failed. By the time the
test assertion runs, no row is still in Running.
The load-bearing SCALE-001 invariant is 'the cap STOPPED at 3.'
Whether the 3 claimed rows ended up Running, Failed, or
Completed is irrelevant to the cap — what matters is that 7
rows STAYED in Pending for the next tick.
Fix: count non-Pending (= claimed) and still-Pending (= 10
minus claimed) separately. Assert claimed=3 and stillPending=7.
LastClaimLimit=3 assertion (already passing in the failed run)
also stays as the seam-propagation pin.
This is a test-fix only — the SCALE-001 production behavior
landed correctly in 037876f and is proven by the CI log line
'count=3 claim_limit=3'.
2026-05-16 04:15:51 +00:00
..
2026-05-13 21:23:35 +00:00
2026-05-14 09:58:46 +00:00
2026-05-14 09:58:46 +00:00
2026-05-14 09:58:46 +00:00
2026-05-14 09:58:46 +00:00
2026-05-14 10:06:06 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-14 10:06:06 +00:00
2026-05-16 04:01:45 +00:00
2026-05-16 04:01:45 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-13 21:23:35 +00:00
2026-05-09 21:03:59 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-04-30 22:33:57 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-14 19:35:51 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-05 19:49:34 +00:00
2026-05-16 03:31:59 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-04-09 23:09:40 -04:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-04-30 15:25:38 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-13 21:23:35 +00:00
2026-04-29 23:57:45 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-13 21:23:35 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 02:14:24 +00:00
2026-05-13 21:23:35 +00:00
2026-05-02 01:27:33 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-16 04:01:45 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-16 04:15:51 +00:00
2026-05-16 04:00:49 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-04-30 06:22:06 +00:00
2026-05-13 21:23:35 +00:00
2026-04-30 04:55:06 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-09 21:03:59 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-05 18:18:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-04-29 18:51:57 +00:00
2026-05-13 21:23:35 +00:00
2026-04-29 13:16:09 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-16 04:01:45 +00:00
2026-05-16 04:01:45 +00:00
2026-05-16 04:01:45 +00:00
2026-05-16 04:01:45 +00:00
2026-05-13 21:23:35 +00:00
2026-05-04 00:30:29 +00:00
2026-05-13 21:23:35 +00:00