removing the double declaration

This commit is contained in:
Mihai 2023-08-03 22:31:37 +03:00
parent 79d48e2b7b
commit 82a37642b4

View file

@ -17,13 +17,7 @@ describe('dateTimeHelpers', () => {
const expected = `${date.getMonth() + 1}/${date.getDate()}/${date.getFullYear()}, ${date.getHours().toString().padStart(2, '0')}:${date.getMinutes().toString().padStart(2, '0')}:${date.getSeconds().toString().padStart(2, '0')}`; const expected = `${date.getMonth() + 1}/${date.getDate()}/${date.getFullYear()}, ${date.getHours().toString().padStart(2, '0')}:${date.getMinutes().toString().padStart(2, '0')}:${date.getSeconds().toString().padStart(2, '0')}`;
expect(formattedDate).toBe(expected); expect(formattedDate).toBe(expected);
expect(formattedTimestamp).toBe(expected); const date = new Date(); expect(formattedTimestamp).toBe(expected);
expect(formatTimestamp(date)).toBe(
date.toLocaleString([], { hour12: false })
);
expect(formatTimestamp(date.getTime())).toBe(
date.toLocaleString([], { hour12: false })
);
}); });
}); });
}); });