/** * NOTE: THIS SHOULD ONLY BE USED IN TESTS. * * Returns a Promise which resolves when `condFn` returns truthy. * The value returned by `condFn` is used to resolve the Promise. * @param condition Function to call. * @param [timeout] How long to wait, in milliseconds (0 = no timeout). * @param [interval=10] How frequently to check, in milliseconds. */ export declare const waitForCondition: any>({ condition, timeout, interval, error, breakOnError, }: { condition: FunctionType; timeout?: number; interval?: number; error?: Error; breakOnError?: boolean; }) => Promise>; export type UntilCallback = (resolve: (value: T) => void, reject: (error: Error) => void) => Promise | void; /** * Awaits promise. */ export declare const until: (cb: UntilCallback, timeout?: number) => Promise; /** * Wait until promise resolves. */ export declare const untilPromise: (cb: () => Promise) => Promise; /** * Wait until error is thrown. */ export declare const untilError: (cb: () => Promise) => Promise; //# sourceMappingURL=testing.d.ts.map