feat(auth): bindProductionAuth self-asserts conformance at tail
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -6,7 +6,9 @@ import {
|
|||||||
type ILogger,
|
type ILogger,
|
||||||
} from "@repo/core-shared/instrumentation";
|
} from "@repo/core-shared/instrumentation";
|
||||||
import type { BindProductionContext } from "@repo/core-shared/di";
|
import type { BindProductionContext } from "@repo/core-shared/di";
|
||||||
|
import { assertFeatureConformance } from "@repo/core-shared/conformance";
|
||||||
import type { ProductionUseCase } from "@repo/core-shared/conformance";
|
import type { ProductionUseCase } from "@repo/core-shared/conformance";
|
||||||
|
import { authManifest } from "../feature.manifest";
|
||||||
import type { AuthManifest } from "../feature.manifest";
|
import type { AuthManifest } from "../feature.manifest";
|
||||||
import type {
|
import type {
|
||||||
SignInInput,
|
SignInInput,
|
||||||
@@ -158,4 +160,17 @@ export function bindProductionAuth(ctx: BindProductionContext): void {
|
|||||||
// <gen:event-handlers>
|
// <gen:event-handlers>
|
||||||
// <gen:jobs>
|
// <gen:jobs>
|
||||||
// <gen:realtime-handlers>
|
// <gen:realtime-handlers>
|
||||||
|
|
||||||
|
// Boot-time conformance check: refuses to start if any use-case binding
|
||||||
|
// is missing a required brand (withSpan / withCapture / withAudit).
|
||||||
|
assertFeatureConformance(
|
||||||
|
authContainer,
|
||||||
|
authManifest,
|
||||||
|
{
|
||||||
|
signIn: AUTH_SYMBOLS.ISignInUseCase,
|
||||||
|
signUp: AUTH_SYMBOLS.ISignUpUseCase,
|
||||||
|
signOut: AUTH_SYMBOLS.ISignOutUseCase,
|
||||||
|
},
|
||||||
|
ctx,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user