@push.rocks/smartexpect
Version:
A testing library to manage expectations in code, offering both synchronous and asynchronous assertion methods.
13 lines • 356 B
text/typescript
/**
* Common types for smartexpect
*/
/** Execution mode: sync or async */
export type TExecutionType = 'sync' | 'async';
/**
* Definition of a custom matcher function.
* Should return an object with `pass` and optional `message`.
*/
export type TMatcher = (
received: any,
...args: any[]
) => { pass: boolean; message?: string | (() => string) };