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

Function completed

e2e/cloud/integrations-api.test.ts:62–69  ·  view source on GitHub ↗
(
  execution: R,
)

Source from the content-addressed store, hash-verified

60
61/** Narrow an execution result to "completed", failing with the run's text. */
62const completed = <R extends { status: string; text: string }>(
63 execution: R,
64): Extract<R, { status: "completed" }> => {
65 if (execution.status !== "completed") {
66 throw new Error(`execution did not complete (status=${execution.status}): ${execution.text}`);
67 }
68 return execution as Extract<R, { status: "completed" }>;
69};
70
71scenario(
72 "Integrations · an OpenAPI spec round-trips the catalog: add, fetch, update, remove",

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected