test(subagent-announce): fix flaky Windows-only test failure (#31298)#31370
test(subagent-announce): fix flaky Windows-only test failure (#31298)#31370Takhoffman merged 2 commits intoopenclaw:mainfrom
Conversation
Greptile SummaryThis PR correctly fixes a Windows-specific flaky test by ensuring Confidence Score: 5/5
Last reviewed commit: 83d7500 |
83d7500 to
b3b699c
Compare
|
PR #31370 - test(subagent-announce): fix flaky Windows-only test failure (#31298) (#31370) Merged after verification.
|
|
PR #31370 - test(subagent-announce): fix flaky Windows-only test failure (#31298) (#31370) Merged after verification.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b3b699c19f
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
|
||
| ### Fixes | ||
|
|
||
| - Tests/Subagent announce: set `OPENCLAW_TEST_FAST=1` before importing `subagent-announce` format suites so module-level fast-mode constants are captured deterministically on Windows CI, preventing timeout flakes in nested completion announce coverage. (#31370) Thanks @zwffff. |
There was a problem hiding this comment.
Drop non-user-facing changelog note
This changelog item describes an internal test-only stabilization (setting OPENCLAW_TEST_FAST before importing a test module) rather than a user-visible behavior change, so it should not be in release notes. The repository guideline in AGENTS.md says “Changelog: user-facing changes only” and that pure test additions/fixes generally do not need a changelog entry, so this line introduces policy-breaking noise in published release history.
Useful? React with 👍 / 👎.
…w#31298) (openclaw#31370) thanks @zwffff Verified: - pnpm install --frozen-lockfile - pnpm build - pnpm check (fails on main baseline issues in extensions/googlechat and extensions/phone-control) - pnpm test:e2e src/agents/subagent-announce.format.e2e.test.ts Co-authored-by: zwffff <5809959+zwffff@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
…w#31298) (openclaw#31370) thanks @zwffff Verified: - pnpm install --frozen-lockfile - pnpm build - pnpm check (fails on main baseline issues in extensions/googlechat and extensions/phone-control) - pnpm test:e2e src/agents/subagent-announce.format.e2e.test.ts Co-authored-by: zwffff <5809959+zwffff@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
…w#31298) (openclaw#31370) thanks @zwffff Verified: - pnpm install --frozen-lockfile - pnpm build - pnpm check (fails on main baseline issues in extensions/googlechat and extensions/phone-control) - pnpm test:e2e src/agents/subagent-announce.format.e2e.test.ts Co-authored-by: zwffff <5809959+zwffff@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
…w#31298) (openclaw#31370) thanks @zwffff Verified: - pnpm install --frozen-lockfile - pnpm build - pnpm check (fails on main baseline issues in extensions/googlechat and extensions/phone-control) - pnpm test:e2e src/agents/subagent-announce.format.e2e.test.ts Co-authored-by: zwffff <5809959+zwffff@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
Summary
Fixes flaky Windows-only test failure in
subagent-announce.format.e2e.test.ts.Problem
The test "waits for updated synthesized output before announcing nested subagent completion" was failing intermittently on Windows CI because:
FAST_TEST_MODEis evaluated at module load time insubagent-announce.tsvi.stubEnv(\"OPENCLAW_TEST_FAST\", \"1\")inbeforeEach, which runs afterbeforeAllwhere the module is importedsetTimeout(100)routinely overshoots to 115-150ms due to default timer resolution (~15.6ms)chatHistorymock callSolution
Move
process.env.OPENCLAW_TEST_FAST = \"1\"tobeforeAllbefore the dynamic module import, so the module-level constant captures the fast mode setting.Changes
OPENCLAW_TEST_FAST=1inbeforeAllbefore importingsubagent-announce.jsvi.stubEnvfrombeforeEachTesting
subagent-announce.format.e2e.test.tspassFixes #31298