Repository navigation
test(server): Windows paths and settings lookup no longer break server tests - #30984
juliusmarminge wants to merge 1 commit into
Conversation
…r tests 17 server tests failed on Windows because of three assumptions that only hold on POSIX. - Claude attachment tests searched JSON.stringify of the SDK content for raw paths, so Windows backslashes appeared doubled. They now read the text blocks, where the attachment prompt writes the raw path. - User-input attachment tests expect the JSON-encoded path that production emits. - The tool-search settings test reads HostProcess.Platform. POSIX assertions are unchanged. On win32 it asserts that the root local file is ignored and a cwd-local file applies. - The Codex shadow home suffix is built with node:path join. AI-assisted; verified with the tests and tools listed above. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This PR adjusts Windows-specific server test expectations and is confined to ignored test files. No production behavior change or material operational exposure is identified. Notes:
You can add or adjust custom eligibility rules. Learn more. |
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
|
Superseded by #30983 |
Problem
On Windows, 17 server tests fail on main because of three test-side assumptions; production is correct and the same files pass on Linux. Attachment tests search JSON-serialized payloads for raw paths, or expect raw paths where production JSON-quotes them, so Windows backslashes never match. The Claude tool-search settings test assumes the POSIX worktree-to-repository-root lookup of
.claude/settings.local.json, while production deliberately reads it from cwd on Windows. A Codex test hard-codes the/-separated suffixproviders/codex/<id>/shadow.Reproduced on main
9e85538535with the Windows test lane: run 41868132030, 17 failed, 311 passed, 13 skipped.Change
Test-only; no production file changes.
ClaudeAdapterV2.test.tsattachments: a smallsdkMessageTexthelper reads the text blocks of the SDK message, and the five path assertions check that text, where production writes the raw path, instead ofJSON.stringifyof the whole content.userInputAttachments.test.ts: the four path assertions expectJSON.stringify(path), the form production emits.ClaudeAdapterV2.test.tstool search: branches onyield* HostProcess.Platform. Off Windows the original assertions are unchanged; on Windows it asserts that the repository-root local file is not read from a worktree or a subdirectory and that a local file in cwd is.CodexDriver.test.ts: the expected suffix is built withNodePath.join.Scope and approval
Fixes #30950
Verification
Windows (
.github/workflows/windows-tests.yml,package=apps/server, the three changed files):9e855385358ca906a282The 17 before-failures are the issue's inventory: 12
ClaudeAdapterV2 attachments, 3userInputAttachments, 1 tool-search settings, 1 Codex managed catalog. The 13 skips are the existing Windows skips in these files.Linux:
vp test runon the three files: 341 passed, before and after.TMPDIRcontaining\): main fails the 15 JSON-path tests; after the change they pass. Four CodexDriver npm-update tests still fail under that simulation on both sides because POSIX production normalizes\to/; that does not happen on Windows and is not changed here.HostProcess.Platformprovided aswin32(temporary, not committed): fails at the root-local assertion on main, passes after.vp run check:changed: passed.No UI or runtime surface changes, so there are no captures.
AI-assisted; verified with the tests and tools listed above.
🤖 Generated with Claude Code