1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

Make fake time have a default value for "now"

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
This commit is contained in:
Iku-turso 2022-09-30 13:24:48 +03:00 committed by Janne Savolainen
parent c7c45e017a
commit 18c2cdf851
No known key found for this signature in database
GPG Key ID: 8C6CFB2FFFE8F68A

View File

@ -16,7 +16,7 @@ export const advanceFakeTime = (milliseconds: number) => {
});
};
export const useFakeTime = (dateTime: string) => {
export const useFakeTime = (dateTime = "2015-10-21T07:28:00Z") => {
usingFakeTime = true;
jest.useFakeTimers();