Skip to content

test(mcp): tear down daemons spawned via cli --json in fixture teardown - #40352

Merged
Simon Knott (Skn0tt) merged 1 commit into
microsoft:mainfrom
Skn0tt:fix-mcp-cli-json-orphan-daemons
Apr 22, 2026
Merged

test(mcp): tear down daemons spawned via cli --json in fixture teardown#40352
Simon Knott (Skn0tt) merged 1 commit into
microsoft:mainfrom
Skn0tt:fix-mcp-cli-json-orphan-daemons

Conversation

@Skn0tt

@Skn0tt Simon Knott (Skn0tt) commented Apr 22, 2026

Copy link
Copy Markdown
Contributor

Summary

The cli fixture extracted the daemon pid from the text-mode marker
`### Browser \`X\` opened with pid N.` only. When tests invoke
`cli('--json', 'open', ...)`, the marker is absent and the daemon
leaked past the test as an orphan process (visible in CI logs as
"Terminate orphan process" lines).

Fall back to parsing the --json envelope's `pid` field so the
teardown loop reaps the daemon regardless of output mode.
@github-actions

Copy link
Copy Markdown
Contributor

Test results for "MCP"

5 failed
❌ [firefox] › mcp/cli-devtools.spec.ts:141 › video-start-stop @mcp-windows-latest
❌ [firefox] › mcp/cli-devtools.spec.ts:155 › video-chapter @mcp-windows-latest
❌ [firefox] › mcp/cli-json.spec.ts:171 › close after open returns closed status @mcp-windows-latest
❌ [firefox] › mcp/cli-session.spec.ts:85 › close-all @mcp-windows-latest
❌ [webkit] › mcp/dashboard.spec.ts:262 › should switch screencast to -s session on show --annotate @mcp-windows-latest

6560 passed, 910 skipped


Merge workflow run.

@Skn0tt
Simon Knott (Skn0tt) merged commit 47146f2 into microsoft:main Apr 22, 2026
8 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants