Repository navigation
Conversation
…events/mcptest Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…eference server Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
alexluong
force-pushed
the
feat/mcp-subscribe-endpoints
branch
from
October 30, 2026 20:51
c374170 to
5cf245d
Compare
alexluong
force-pushed
the
feat/mcp-test-harness
branch
from
October 30, 2026 20:51
92e557e to
ae4fc36
Compare
This branch has not been deployed
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.
Add a library that checks an MCP Events (draft SEP-3415) server against the draft's webhook flow, and move the e2e test client, receiver and server into it so the e2e suites and the checks share one implementation. Test code only, under
internal/mcpevents/mcptest; Outpost itself doesn't change.Stacked on #1183.
Changes
internal/mcpevents/mcptest/{mcpclient,mcpreceiver,mcpserver}. The e2e suites change imports only. None of the packages importsinternal/mcpevents, so the checks never reuse the code they check._metainstead of using a session, and the reference server answersserver/discoverwith the events extension. Theinitializeresult doesn't advertise a top-levelcapabilities.events: the draft defines events only as an extension.401without echoing a challenge to requests no configured secret verifies, and checksX-MCP-Subscription-Idand signedgapandterminatedenvelopes. It has two rule profiles:outpost(the e2e default: Outpost's own choices such as thewebhook-idform) andspec(only what the draft requires).mcpcheck.Runruns the webhook flow against a server and reports one result per rule with the draft section behind it:PASS,FAIL(a MUST is missed),WARN(a SHOULD is missed, or something the draft allows is unusual),SKIP(a precondition failed). It covers discovery,events/listdescriptors and paging, auth and header checks, subscribe errors, callback verification, delivery envelope, signature and headers, retries, refresh and secret rotation, argument filtering, isolation between principals, and unsubscribe.Behavior changes
Test code only. The e2e receiver requires
X-MCP-Subscription-Idon every delivery and an object indata; a miss means a real Outpost bug.Tests
TestMCP_Check(e2e) runsmcpcheckagainst the reference server in front of the e2e Outpost, publishing through Outpost's API, and fails on anyFAIL. Themcpcheckunit tests include two injected faults (the server ignoresMcp-Name, signs with a wrong secret), so the checks are shown to fail.To run:
go test -short -race ./internal/mcpevents/mcptest/...for the unit tests;make up/test, thenTESTINFRA=1 make test/e2e RUN=TestMCP_Checkfor the e2e check.Not in this PR
events/poll,events/stream,listChanged.WARN).maxAgeMs,truncated,gapandterminatedare shape-checked when they appear and never triggered.v1asignatures are ignored. Address-guard and redirect rules aren't probed; the Outpost e2e suites cover them.initializeand sessions; moving them to stateless discovery is a follow-up.🤖 Generated with Claude Code