1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-10-18 20:09:08 +02:00

fix(jest) Always use UTC as TZ

This commit is contained in:
Ivar Conradi Østhus 2018-02-02 12:05:44 +00:00
parent 6cf9c689db
commit 03ff3b8a74
2 changed files with 4 additions and 4 deletions

View File

@ -2,4 +2,4 @@
// We have set timezone to make sure tests are correct
process.env.TZ = 'UTC';
process.TZ = 'UTC';

View File

@ -1,7 +1,7 @@
import { formatFullDateTime } from '../util';
test('formats dates correctly', () => {
expect(formatFullDateTime(1487861809466)).toEqual('2017-02-23 15:56:49');
expect(formatFullDateTime(1487232809466)).toEqual('2017-02-16 09:13:29');
expect(formatFullDateTime(1477232809466)).toEqual('2016-10-23 16:26:49');
expect(formatFullDateTime(1487861809466)).toEqual('2017-02-23 14:56:49');
expect(formatFullDateTime(1487232809466)).toEqual('2017-02-16 08:13:29');
expect(formatFullDateTime(1477232809466)).toEqual('2016-10-23 14:26:49');
});