test: fix remaining release protocol handshake fixtures
Summary
- Finish the protocol-relative fixture updates missed in #2908.
- Derive extension RPC handshake fixtures from the current protocol version instead of hardcoding
1.0.9,1.1.0, and2.0.0. - Preserve coverage for patch compatibility, newer-client minor rejection, major mismatch, and prerelease mismatch without changing runtime behavior.
Root cause
Release PR #2798 bumps the protocol to 2.0.0. The extension tests still assumed a 1.0.0 server: 1.0.9 was expected to succeed, 1.1.0 was expected to fail specifically because the server minor was too old, and 2.0.0 was expected to fail with a major mismatch.
These five failures were already present in the original CI log; #2908 fixed the SDK-side fixtures but missed the extension-side fixtures. The refreshed release commit only adds #2908, so these are remaining failures rather than a new runtime regression.
Validation
- Reproduced exactly five failures across
rpc-client.test.tsandrpc-router.test.tswith protocol2.0.0before this patch. - After the patch, both files pass all 25 tests with protocol
2.0.0. - Both files also pass all 25 tests with protocol
1.0.0and a simulated future2.3.4. - Full
pnpm exec turbo run test:unit --forcepasses with protocol2.0.0: all 32 tasks succeed with no cache hits, including all 355 extension tests and 272 SDK tests (10 existing extension TODOs). - Extension TypeScript typecheck, targeted oxlint/oxfmt, and
git diff --checkpass.
Temporary protocol version changes were reverted before committing. Test-only follow-up; no changeset or production version bump required. GitHub CI still needs to run on this PR.
Summary by cubic
Fixes extension RPC handshake tests that broke after the protocol version bumped to 2.0.0 by deriving test fixtures from the current protocol version.
Bug Fixes
- Hardcoded
1.0.9,1.1.0, and2.0.0fixtures assumed a1.0.0server, causing five failures acrossrpc-client.test.tsandrpc-router.test.ts. - Fixtures now use
STAGEHAND_PROTOCOL_VERSION, so they stay in sync with future bumps. - Patch compatibility, minor rejection, major mismatch, and prerelease mismatch coverage is preserved.
- Test-only change; no changeset or runtime impact.