Repository navigation
test: neutralize Windows-local broker and ci-audit fixture assumptions - #1637
Conversation
The accounting matrix executed real Unix shells (/bin/sh, /bin/sleep) through the production runner, so every case skipped on Windows and the required build never ran; fixtures now follow the platform shell spelling (COMSPEC /C exits, a single-process powershell sleeper the direct-child kill can reap). The ci repair pagination fake API alone hardcoded a 2s serve deadline and stream timeouts while eight sequential curl spawns run against it; it now uses the shared idle-deadline and stream-timeout constants its sibling fixtures already use.
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Next included review available in 17 minutes. View limit details
|
EffortlessSteven
left a comment
There was a problem hiding this comment.
Source-only review of head ef68560f0fdaa4307e9a5c4f4745296b4e017fed against base e4bff4644f596d0a7ddc8685651a3ac3ea1ce1a9: no actionable source defects found in the two changed test fixtures.
The Windows shell/sleeper selection is consistent with the runner's direct-child termination behavior. The pagination timeout changes match sibling fixtures while preserving the request-count and pagination assertions. The cancellation case still receives nonzero error-duration accounting through the existing minimum 1 ms measurement.
One description correction: Unix behavior is not byte-identical. The cancellation fixture now uses /bin/sh -c "exit 0" instead of /bin/sleep 0.05. Its completion-then-simulated-cancellation semantics remain.
Limits: no candidate execution was performed for this review. Windows execution and raw Windows receipts were not independently verified; the Windows results in the PR description remain author-reported. This review does not establish elimination of the load-triggered flake or CI qualification.
Fixes the two remaining Windows-local failures tracked in #1628 (after #1630 resolved the three path-spelling failures). Both reproduced and both now pass on a local Windows checkout of current main.
1.
proof::broker::tests::accounting_matrix_releases_early_commands_before_required_buildObserved on Windows: every proof command fixture (
/bin/sh -c exit 0|7,/bin/sleep) failed to spawn (os error 3), the broker recordedskipped_profilereceipts, the required build never executed, and the run ended withtimeout: required build executions=1.Fix: the fixtures now follow the repo's platform-shell idiom (
#[cfg(unix)]/bin/sh,#[cfg(windows)]COMSPEC /C), matchinglane_packets.rsandgithub_delivery.rs:exit_fixture_argv(0|7)— exit codes propagate identically (verified:exit code Some(7)discriminating receipt),powershell -NoProfile -Command "Start-Sleep -Seconds 10": cmd'stimeoutbuiltin refuses redirected consoles, and a nestedpingwould outlive the runner's direct-childkill()(no tree kill inrun_command_to_files_inner),exit_fixture_argv(0); the nonzero-duration_msassertion still holds on a real exec.Validation (Windows local): the test now passes (14.6s, all five cases) where it previously failed deterministically. Linux behavior is byte-identical for unix cfgs (same
/bin/shfixtures as before), exercised by the gate.2.
tests::ci_audit_tests::ci_repair_pagination_uses_raw_page_not_decoded_populationObserved on Windows: intermittent failures under load. The fake API is the only
serve_fake_httpuser hardcoding a 2s deadline and 2s stream timeouts, while the client performs 8 sequential real-curl requests against it; under full-suite parallel load the budget expires mid-conversation.Fix: use the shared
super::FAKE_HTTP_IDLE_DEADLINE(120s idle deadline, reset per accepted request) andsuper::FAKE_HTTP_STREAM_TIMEOUT(30s) exactly like every sibling fixture in this file. The oracle (pagination via raw page rows, not decoded population) is unchanged.Validation (Windows local): 3/3 isolated passes after the fix, plus the full serial
tests::ci_audit_testsmodule (45/45). The intermittent is load-triggered, so the gate's Linux run plus these constants (already proven by sibling tests) are the durable evidence.Scope
Test-only. No production behavior, timeout budgets (#992/#1503), or gate wiring changes.