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

Function redirected

e2e/cloud/oauth-connections.test.ts:33–40  ·  view source on GitHub ↗
(
  result: R,
)

Source from the content-addressed store, hash-verified

31
32/** Narrow a `start` result to the redirect arm, failing with what came back. */
33const redirected = <R extends { status: string }>(
34 result: R,
35): Extract<R, { status: "redirect" }> => {
36 if (result.status !== "redirect") {
37 throw new Error(`oauth.start did not redirect: ${JSON.stringify(result)}`);
38 }
39 return result as Extract<R, { status: "redirect" }>;
40};
41
42scenario(
43 "OAuth · probe discovers an authorization server's endpoints from its issuer URL",

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected