arvo-event-handler
    Preparing search index...

    Type Alias ArvoTestConfig

    ArvoTestConfig: { name?: string } & (
        | { fn?: never; handler?: IArvoEventHandler }
        | {
            fn?: (event: ArvoEvent) => Promise<{ events: ArvoEvent[] }>;
            handler?: never;
        }
    )

    Configuration for the event handler or function under test.

    Supports testing either an IArvoEventHandler instance or a raw async function. Multiple configs can be provided to test the same cases against different implementations.

    Type Declaration

    • Optionalname?: string

      Optional display name for the test suite. If not provided, defaults to the handler source or function name.

    • { fn?: never; handler?: IArvoEventHandler }
      • Optionalfn?: never
      • Optionalhandler?: IArvoEventHandler

        IArvoEventHandler instance to test.

    • { fn?: (event: ArvoEvent) => Promise<{ events: ArvoEvent[] }>; handler?: never }
      • Optionalfn?: (event: ArvoEvent) => Promise<{ events: ArvoEvent[] }>

        Raw async function to test that accepts an ArvoEvent and returns events.

      • Optionalhandler?: never