Interface for asynchronous property defining hooks, see IAsyncProperty

Remarks

Since 2.2.0

interface IAsyncPropertyWithHooks<Ts> {
    runAfterEach?: (() => Promise<void>);
    runBeforeEach?: (() => Promise<void>);
    afterEach(hookFunction): IAsyncPropertyWithHooks<Ts>;
    beforeEach(hookFunction): IAsyncPropertyWithHooks<Ts>;
    generate(mrng, runId?): Value<Ts>;
    isAsync(): true;
    run(v, dontRunHook?): Promise<null | PreconditionFailure | PropertyFailure>;
    shrink(value): Stream<Value<Ts>>;
}

Type Parameters

  • Ts

Hierarchy (view full)

Properties

runAfterEach?: (() => Promise<void>)

Run after each hook

Type declaration

    • (): Promise<void>
    • Returns Promise<void>

Remarks

Since 3.4.0

runBeforeEach?: (() => Promise<void>)

Run before each hook

Type declaration

    • (): Promise<void>
    • Returns Promise<void>

Remarks

Since 3.4.0

Methods