MCPcopy Create free account
hub / github.com/arktypeio/arktype / contextualizeEach

Function contextualizeEach

ark/attest/utils.ts:99–108  ·  view source on GitHub ↗
(name, createCtx, tests)

Source from the content-addressed store, hash-verified

97}
98
99const contextualizeEach: ContextualizeEach = (name, createCtx, tests) => {
100 const describe = globalThis.describe
101 if (!describe) throwNoDescribeError()
102
103 describe(name, () =>
104 tests((name, test) => {
105 it(name, () => test(createCtx()))
106 })
107 )
108}
109
110export const contextualize: Contextualize = Object.assign(contextualizeRoot, {
111 each: contextualizeEach

Callers

nothing calls this directly

Calls 3

throwNoDescribeErrorFunction · 0.85
describeFunction · 0.50
itFunction · 0.50

Tested by

no test coverage detected