Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(coverage-runner-status): correct test for pending status handling\n\nUpdated the test to properly verify that the coverage runner correctly handles the pending status transition, ensuring the test reflects the expected behavior when a job moves from queued to in-progress.\n\nAuto-committed-on: dragonfly\n

Steven Enamakelfc45c9d51454
diff --git a/scripts/__tests__/coverage-runner-status.test.mjs b/scripts/__tests__/coverage-runner-status.test.mjs
index 58af70d44c..34091420a5 100644
--- a/scripts/__tests__/coverage-runner-status.test.mjs
+++ b/scripts/__tests__/coverage-runner-status.test.mjs
@@ -59,6 +59,13 @@ function extractFunction(name) {
function withRunnerFunctions(functions, preamble, body) {
const script = [
"set -euo pipefail",
+ // Merge stderr into stdout for the whole script, including the success
+ // path. A `case`/`if !` guard around an undefined helper can turn bash's
+ // status-127 "command not found" into a handled branch rather than a
+ // thrown error, so execFileSync's success path — which otherwise only
+ // returns stdout — would never see it and the guard below would miss a
+ // real extraction drift.
+ "exec 2>&1",
extractTestsRunDecl(),
preamble,
...functions.map(extractFunction),