mirror of
https://github.com/immich-app/immich.git
synced 2025-01-07 00:50:23 -05:00
fix(web): time zone dependent test (#13859)
This commit is contained in:
parent
b238b69689
commit
0b98c5e3c4
1 changed files with 2 additions and 0 deletions
|
@ -5,11 +5,13 @@ import { DateTime } from 'luxon';
|
||||||
describe('formatGroupTitle', () => {
|
describe('formatGroupTitle', () => {
|
||||||
beforeAll(() => {
|
beforeAll(() => {
|
||||||
vi.useFakeTimers();
|
vi.useFakeTimers();
|
||||||
|
process.env.TZ = 'UTC';
|
||||||
vi.setSystemTime(new Date('2024-07-27T12:00:00Z'));
|
vi.setSystemTime(new Date('2024-07-27T12:00:00Z'));
|
||||||
});
|
});
|
||||||
|
|
||||||
afterAll(() => {
|
afterAll(() => {
|
||||||
vi.useRealTimers();
|
vi.useRealTimers();
|
||||||
|
delete process.env.TZ;
|
||||||
});
|
});
|
||||||
|
|
||||||
it('formats today', () => {
|
it('formats today', () => {
|
||||||
|
|
Loading…
Reference in a new issue