Setu-TS
    Preparing search index...

    Interface MockPluginOptions

    Options for createMockPlugin.

    0.1.0

    interface MockPluginOptions {
        name: string;
        priority?: number;
        provides?: string;
        register?: (ctx: IPluginContext) => void | Promise<void>;
        service: object;
    }
    Index
    name: string

    Plugin name (also used as the capability token when provides is absent).

    priority?: number

    Registration priority; passed through to the kernel resolver. Omitted when not needed (the returned plugin omits priority too).

    provides?: string

    Capability token this plugin provides. Defaults to name. Override when the plugin name differs from the capability token.

    register?: (ctx: IPluginContext) => void | Promise<void>

    Additional registration callback invoked during register(ctx). Useful for registering middleware, routes, or lifecycle hooks alongside the mock service.

    service: object

    The mock service object to register.