Skip to content

Commit ef42dcd

Browse files
author
jin
committed
short date
1 parent ef4cfdd commit ef42dcd

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

vary/diagram/examples.png

6.36 KB
Loading

vary/vary.test.ts

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,10 +212,16 @@ namespace $.$$ {
212212

213213
"vary pack Date"( $ ) {
214214

215-
const date = new Date( '2025-01-02T03:04:05.678' )
215+
const date1 = new Date( '2025-01-02T03:04:05' )
216216
check(
217-
date,
218-
[ tupl|1, text|9, ... str('unix_time'), fp64, ... new Uint8Array( new Float64Array([ date.valueOf() / 1000 ]).buffer ) ],
217+
date1,
218+
[ tupl|1, text|9, ... str('unix_time'), uint|l4, ... new Uint8Array( new Uint32Array([ date1.valueOf() / 1000 ]).buffer ) ],
219+
)
220+
221+
const date2 = new Date( '2025-01-02T03:04:05.678' )
222+
check(
223+
date2,
224+
[ tupl|1, text|9, ... str('unix_time'), fp64, ... new Uint8Array( new Float64Array([ date2.valueOf() / 1000 ]).buffer ) ],
219225
)
220226

221227
},

0 commit comments

Comments
 (0)