Repository navigation
fix: align task-owner tests with installed service environment - #187967
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
Contributor
Author
|
Fixed: scheduled-task owner termination tests now expect the installed service environment. |
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Oct 30, 2026
…law#187967) Restore the scheduled-task stop fixture’s exact installed-service environment assertion while preserving its process identity and termination controls. Refs openclaw#187901.
RomneyDa
added a commit
that referenced
this pull request
Oct 30, 2026
Restore the scheduled-task stop fixture’s exact installed-service environment assertion while preserving its process identity and termination controls. Refs #187901. (cherry picked from commit 0078d6a) Co-authored-by: RomneyDa <[email protected]>
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.
What Problem This Solves
The scheduled-task stop suite fails its two validated-owner cases after #187901: when an owner becomes unknown or loses its lease, the test still expects PID start-time probes to receive the inspecting CLI’s profile. The installed launcher in this fixture declares only the Gateway port, so the service environment correctly omits that caller-only selector.
User Impact
This is a test-only correction with no change to Windows task operations. It restores the existing checks for completing termination of the captured process while retaining the exact PID, five-second probe bound, graceful-before-forced ordering, foreign-process exclusion, and prohibition on a kill-tree fallback.
Why This Change Was Made
The assertion now names the fixture’s expected service environment directly: its user directory, application-data directory, and installed port. It remains an exact environment comparison and does not derive its answer from the production merge helper. The shared launcher and production environment-isolation contract remain unchanged.
The explicit assertion needs five additional test lines, covered by one matching allocation record. No test case or helper is added.
Evidence
The clean baseline at 9559c51 ran all 30 stop-suite cases: 28 passed and these two failed solely because the expected environment contained
OPENCLAW_PROFILE=default. The fixture, environment merge, process owner and determining test inputs are unchanged at this branch’s fe8a0ce base.On the candidate, remote formatting, lint, and selected production/test type checks passed. All 131 cases across the seven selected files passed: the full scheduled-task stop suite, its shared-fixture consumers, and the environment-merge owner. The six-file daemon cohort took 36.63 seconds; the complete selected test batch took 39.49 seconds. Hosted CI passed on this exact head. These are Linux-hosted tests with mocked Windows process boundaries; they do not claim a real Windows Task Scheduler run.