1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00
lens/src/common/test-utils/flush-promises.ts
Janne Savolainen 9c420d6f1e
Try solving flaky unit test by switch to use different implementation of setImmediate (#5655)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-16 09:57:32 -04:00

8 lines
249 B
TypeScript

/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import { setImmediate } from "timers";
export const flushPromises = () => new Promise(setImmediate);