Repository navigation
test(agents): consolidate cleanup timeout and revocation coverage - #139937
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
steipete
marked this pull request as ready for review
September 6, 2026 08:27
Contributor
Author
|
Merged via squash.
|
This was referenced Sep 6, 2026
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Sep 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: #135868, #139657
What Problem This Solves
The Stage 3 cleanup-evidence suite repeated timeout setup and inspected authority callback shapes alongside tests of the actual caller boundary. This is the maintainer-requested test-debt follow-up for concern C of the #135868 split.
Why This Change Was Made
Put all seven timeout-policy cases in one table with the same before-deadline and exact-deadline assertions. Combine the revoked-restart case with the existing revoked-access/owned-cleanup case, and retain observable caller errors and successor usability instead of checking whether an internal assertion callback is a function.
User Impact
No runtime behavior changes. Test code shrinks by 97 lines (70 added / 167 deleted); production, tooling and docs each change by zero. Of that reduction, 19 lines are in the new Stage 3 CLI tests; 78 remove older policy repetition in the cleanup suite Stage 3 extended.
Evidence
All removed cases retain named coverage in the final files:
src/agents/run-cleanup-timeout.test.ts:94, “bounds stalled cleanup with $name”, seven named table rowssrc/agents/cli-runner/cli-live-session-registry.test.ts:259, “fences caller-revoked live access while allowing its owned cleanup”, now includes restart rejection and no premature closesrc/agents/cli-runner/cli-live-session-registry.test.ts:277, “rechecks caller authority after registered process cleanup”src/agents/cli-runner/execute-plugin.test.ts:239, “does not close a successor or execute after caller revocation during restart cleanup”The nested-uncertainty and original-result cases (
run-cleanup-timeout.test.ts:218,273), distinct CLI retirement races, and real-process cleanup suites remain intact.execute-plugin.test-support.tshas two consumers, so inlining it would duplicate fixtures.Validation: 88 focused tests passed across the three edited suites; full
node scripts/check-changed.mjsexited 0, including both agent test type graphs, lint and all three dead-export scans. Independent Codex autoreview: scoped-clean through P2.git diff --checkpassed.