MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / withServer

Function withServer

packages/plugins/mcp/src/sdk/probe-shape.test.ts:44–50  ·  view source on GitHub ↗
(handler: ProbeHandler, use: (endpoint: string) => Effect.Effect<A, E>)

Source from the content-addressed store, hash-verified

42 });
43
44const withServer = <A, E>(handler: ProbeHandler, use: (endpoint: string) => Effect.Effect<A, E>) =>
45 Effect.scoped(
46 Effect.gen(function* () {
47 const server = yield* serveProbeEndpoint(handler);
48 return yield* use(server.endpoint);
49 }),
50 );
51
52describe("probeMcpEndpointShape", () => {
53 it.effect("classifies 2xx as unauth-OK MCP", () =>

Callers 1

Calls 2

serveProbeEndpointFunction · 0.85
useFunction · 0.70

Tested by

no test coverage detected