Skip to content

Commit 4f60f3c

Browse files
committed
Stabilize ConEmu snapshot date
1 parent 20022f8 commit 4f60f3c

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

src/infrastructure/serialization/scheme-exports/conemu.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,13 @@ function padDatePart(value) {
4444

4545
function conEmuModifiedDate(date) {
4646
return [
47-
date.getFullYear(),
48-
padDatePart(date.getMonth() + 1),
49-
padDatePart(date.getDate()),
47+
date.getUTCFullYear(),
48+
padDatePart(date.getUTCMonth() + 1),
49+
padDatePart(date.getUTCDate()),
5050
].join('-') + ' ' + [
51-
padDatePart(date.getHours()),
52-
padDatePart(date.getMinutes()),
53-
padDatePart(date.getSeconds()),
51+
padDatePart(date.getUTCHours()),
52+
padDatePart(date.getUTCMinutes()),
53+
padDatePart(date.getUTCSeconds()),
5454
].join(':');
5555
}
5656

tests/infrastructure/serialization/scheme-exporters.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ describe('SchemeExporters', () => {
8484
});
8585

8686
it('generates a ConEmu palette XML fragment', async () => {
87-
const dateNowSpy = vi.spyOn(Date, 'now').mockReturnValue(1519081200000);
87+
const dateNowSpy = vi.spyOn(Date, 'now').mockReturnValue(1519084800000);
8888

8989
try {
9090
const blob = buildSchemeDownload('conEmu', createColors());
@@ -99,7 +99,7 @@ describe('SchemeExporters', () => {
9999
expect(text).toContain('<value name="ColorTable31" type="dword" data="00ffffff"/>');
100100
expect(text).toMatchInlineSnapshot(`
101101
"<key name="Palette1" modified="2018-02-20 00:00:00" build="180131">
102-
<value name="Name" type="string" data="4bit generated 1519081200" />
102+
<value name="Name" type="string" data="4bit generated 1519084800" />
103103
<value name="ExtendColors" type="hex" data="00" />
104104
<value name="ExtendColorIdx" type="hex" data="0E" />
105105
<value name="TextColorIdx" type="hex" data="10"/>

0 commit comments

Comments
 (0)