Skip to content

Commit 968c077

Browse files
betegonclaude
andcommitted
fix(e2e): add missing .npmrc and fix transport assertion in node-express-mcp-v2
Without .npmrc, pnpm resolves @sentry/* from the public registry instead of Verdaccio, so the published validateMcpServerInstance (v1-only) rejects the v2 McpServer and no instrumentation is applied — causing the 30s timeout. Also fix the mcp.transport assertion: NodeStreamableHTTPServerTransport proxies onmessage to its inner WebStandardStreamableHTTPServerTransport, so constructor.name in the wrapper is the inner class. Use the broader /StreamableHTTPServerTransport/ regex (matching the v1 test pattern). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 8b22796 commit 968c077

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
@sentry:registry=http://127.0.0.1:4873
2+
@sentry-internal:registry=http://127.0.0.1:4873

dev-packages/e2e-tests/test-applications/node-express-mcp-v2/tests/mcp.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ test('Should record transactions for MCP handlers using @modelcontextprotocol/sd
2626
expect(initializeTransaction.contexts?.trace?.data?.['mcp.method.name']).toEqual('initialize');
2727
expect(initializeTransaction.contexts?.trace?.data?.['mcp.client.name']).toEqual('test-client-v2');
2828
expect(initializeTransaction.contexts?.trace?.data?.['mcp.server.name']).toEqual('Echo-V2');
29-
expect(initializeTransaction.contexts?.trace?.data?.['mcp.transport']).toMatch(/NodeStreamableHTTPServerTransport/);
29+
expect(initializeTransaction.contexts?.trace?.data?.['mcp.transport']).toMatch(/StreamableHTTPServerTransport/);
3030
});
3131

3232
await test.step('registerTool handler', async () => {

0 commit comments

Comments
 (0)