MCPcopy Create free account
hub / github.com/Effect-TS/effect / layerTest

Function layerTest

packages/effect/src/graphql/GraphQLClient.ts:892–898  ·  view source on GitHub ↗
(
  service: Context.Key<I, Service>,
  group: GraphQLGroup.GraphQLGroup<Ops> & (GraphQLClient<Ops> extends NoInfer<Service> ? unknown : never)
)

Source from the content-addressed store, hash-verified

890 * @since 4.0.0
891 */
892export const layerTest = <I, Service, Ops extends GraphQL.Any>(
893 service: Context.Key<I, Service>,
894 group: GraphQLGroup.GraphQLGroup<Ops> & (GraphQLClient<Ops> extends NoInfer<Service> ? unknown : never)
895) =>
896(handlers: TestHandlers<Ops>): Layer.Layer<I> =>
897 // The group constraint checks that the mock satisfies the service shape.
898 Layer.succeed(service, makeTest(group)(handlers) as unknown as Service)
899
900// Handlers are called through these erased signatures; `makeTest` has
901// already checked them against the operation.

Callers

nothing calls this directly

Calls 2

makeTestFunction · 0.85
succeedMethod · 0.45

Tested by

no test coverage detected