Skip to content

ValidationConformanceFixture

ValidationConformanceFixture = object

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:19

Builders that the adapter author supplies to satisfy the validation conformance suite. Each builder’s RETURN TYPE encodes the expected phantom job type definitions, so the adapter’s schema-to-shape mapper must thread inference correctly to type-check at the call site of runValidationAdapterConformance.

Conformance verifies the wrapper layer only — the six runtime methods and the way they integrate with core’s createJobTypes error wrapping. Compile-time validation rules (rejecting blockers that reference continuation-only types, etc.) live in core’s ValidatedJobTypeDefinitions and are tested there; the positive type checks below are sufficient to prove the adapter feeds them correctly.

basic: object

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:25

buildContinuationOnly: () => JobTypes<{ main: { blockers: undefined; continueWith: { typeName: "next"; }; entry: true; input: { id: string; }; output: undefined; }; next: { blockers: undefined; continueWith: undefined; entry: undefined; input: { data: string; }; output: { done: boolean; }; }; }>

main → next (continuation-only entry): main: entry, input { id: string }, no output, continueWith nominal “next”. next: non-entry, input { data: string }, output { done: boolean }.

JobTypes<{ main: { blockers: undefined; continueWith: { typeName: "next"; }; entry: true; input: { id: string; }; output: undefined; }; next: { blockers: undefined; continueWith: undefined; entry: undefined; input: { data: string; }; output: { done: boolean; }; }; }>

buildEntry: () => JobTypes<{ main: { blockers: undefined; continueWith: undefined; entry: true; input: { id: string; }; output: { ok: boolean; }; }; }>

main: entry, input { id: string }, output { ok: boolean } — no continueWith, no blockers.

JobTypes<{ main: { blockers: undefined; continueWith: undefined; entry: true; input: { id: string; }; output: { ok: boolean; }; }; }>

buildNonEntry: () => JobTypes<{ internal: { blockers: undefined; continueWith: undefined; entry: undefined; input: { id: string; }; output: { ok: boolean; }; }; }>

internal: non-entry, input { id: string }, output { ok: boolean }.

JobTypes<{ internal: { blockers: undefined; continueWith: undefined; entry: undefined; input: { id: string; }; output: { ok: boolean; }; }; }>


blockers: object

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:106

buildNominal: () => JobTypes<{ auth: { blockers: undefined; continueWith: undefined; entry: true; input: { token: string; }; output: { userId: string; }; }; main: { blockers: readonly object[]; continueWith: undefined; entry: true; input: { id: string; }; output: { done: boolean; }; }; }>

main blocked nominally by ‘auth’.

JobTypes<{ auth: { blockers: undefined; continueWith: undefined; entry: true; input: { token: string; }; output: { userId: string; }; }; main: { blockers: readonly object[]; continueWith: undefined; entry: true; input: { id: string; }; output: { done: boolean; }; }; }>

buildStructural: () => JobTypes<{ auth: { blockers: undefined; continueWith: undefined; entry: true; input: { token: string; }; output: { userId: string; }; }; main: { blockers: readonly object[]; continueWith: undefined; entry: true; input: { id: string; }; output: { done: boolean; }; }; }>

main blocked structurally by anything with input { token: string }.

JobTypes<{ auth: { blockers: undefined; continueWith: undefined; entry: true; input: { token: string; }; output: { userId: string; }; }; main: { blockers: readonly object[]; continueWith: undefined; entry: true; input: { id: string; }; output: { done: boolean; }; }; }>


continuations: object

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:69

buildNominal: () => JobTypes<{ step1: { blockers: undefined; continueWith: { typeName: "step2"; }; entry: true; input: { id: string; }; output: undefined; }; step2: { blockers: undefined; continueWith: undefined; entry: undefined; input: { data: unknown; }; output: { done: boolean; }; }; }>

step1 → step2 (nominal continueWith by name).

JobTypes<{ step1: { blockers: undefined; continueWith: { typeName: "step2"; }; entry: true; input: { id: string; }; output: undefined; }; step2: { blockers: undefined; continueWith: undefined; entry: undefined; input: { data: unknown; }; output: { done: boolean; }; }; }>

buildStructural: () => JobTypes<{ handler: { blockers: undefined; continueWith: undefined; entry: undefined; input: { payload: string; }; output: { handled: boolean; }; }; router: { blockers: undefined; continueWith: { input: { payload: string; }; }; entry: true; input: { route: string; }; output: undefined; }; }>

router → handler (structural continueWith by input shape).

JobTypes<{ handler: { blockers: undefined; continueWith: undefined; entry: undefined; input: { payload: string; }; output: { handled: boolean; }; }; router: { blockers: undefined; continueWith: { input: { payload: string; }; }; entry: true; input: { route: string; }; output: undefined; }; }>


optional dispose?: () => Promise<void>

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:24

Optional hook called once after all conformance cases finish (pass or fail) to release any resources the adapter held.

Promise<void>


external: object

Defined in: packages/core/src/conformance/validation-adapter-cases.ts:149

Cross-slice external typing. Every adapter must thread the external generic so multi-slice setups type correctly. The two-arg JobTypes<TInternal, TExternal> return type makes this verifiable at the fixture call site.

buildWithExternalSlice: () => JobTypes<{ orders.confirm-order: { blockers: readonly [{ typeName: "notifications.send-notification"; }]; continueWith: undefined; entry: undefined; input: { orderId: number; }; output: { confirmedAt: string; }; }; orders.place-order: { blockers: undefined; continueWith: { typeName: "orders.confirm-order"; }; entry: true; input: { userId: string; }; output: undefined; }; }, { notifications.send-notification: { blockers: undefined; continueWith: undefined; entry: true; input: { message: string; userId: string; }; output: { sentAt: string; }; }; }>

JobTypes<{ orders.confirm-order: { blockers: readonly [{ typeName: "notifications.send-notification"; }]; continueWith: undefined; entry: undefined; input: { orderId: number; }; output: { confirmedAt: string; }; }; orders.place-order: { blockers: undefined; continueWith: { typeName: "orders.confirm-order"; }; entry: true; input: { userId: string; }; output: undefined; }; }, { notifications.send-notification: { blockers: undefined; continueWith: undefined; entry: true; input: { message: string; userId: string; }; output: { sentAt: string; }; }; }>

buildWithExternalSlices: () => JobTypes<{ orders.confirm-order: { blockers: readonly [{ typeName: "notifications.send-notification"; }, { typeName: "payments.charge"; }]; continueWith: undefined; entry: undefined; input: { orderId: number; }; output: { confirmedAt: string; }; }; orders.place-order: { blockers: undefined; continueWith: { typeName: "orders.confirm-order"; }; entry: true; input: { userId: string; }; output: undefined; }; }, { notifications.send-notification: { blockers: undefined; continueWith: undefined; entry: true; input: { message: string; userId: string; }; output: { sentAt: string; }; }; } | { payments.charge: { blockers: undefined; continueWith: undefined; entry: true; input: { amount: number; }; output: { receiptId: string; }; }; }>

Cross-slice external typing where the consuming slice references job types from TWO external slices, passed as a readonly array. Adapters that only thread a single-slice external (the 0.11 mergeJobTypeRegistries regression) won’t satisfy this return type.

JobTypes<{ orders.confirm-order: { blockers: readonly [{ typeName: "notifications.send-notification"; }, { typeName: "payments.charge"; }]; continueWith: undefined; entry: undefined; input: { orderId: number; }; output: { confirmedAt: string; }; }; orders.place-order: { blockers: undefined; continueWith: { typeName: "orders.confirm-order"; }; entry: true; input: { userId: string; }; output: undefined; }; }, { notifications.send-notification: { blockers: undefined; continueWith: undefined; entry: true; input: { message: string; userId: string; }; output: { sentAt: string; }; }; } | { payments.charge: { blockers: undefined; continueWith: undefined; entry: true; input: { amount: number; }; output: { receiptId: string; }; }; }>