UNPKG

@daiso-tech/core

Version:

The library offers flexible, framework-agnostic solutions for modern web applications, built on adaptable components that integrate seamlessly with popular frameworks like Next Js.

26 lines (25 loc) 896 B
/** * @module EventBus */ import { type TestAPI, type SuiteAPI, type ExpectStatic, type beforeEach } from "vitest"; import { type IEventBus } from "../../../event-bus/contracts/_module-exports.js"; import { type Promisable } from "../../../utilities/_module-exports.js"; /** * * IMPORT_PATH: `"@daiso-tech/core/event-bus/test-utilities"` * @group TestUtilities */ export type EventBusTestSuiteSettings = { expect: ExpectStatic; test: TestAPI; describe: SuiteAPI; beforeEach: typeof beforeEach; createEventBus: () => Promisable<IEventBus>; }; /** * The `eventBusTestSuite` function simplifies the process of testing your custom implementation of {@link IEventBus | `IEventBus`} with vitest. * * IMPORT_PATH: `"@daiso-tech/core/event-bus/test-utilities"` * @group TestUtilities */ export declare function eventBusTestSuite(settings: EventBusTestSuiteSettings): void;