提交 cfdbc90b 编写于 作者: 杜庆泉's avatar 杜庆泉

Date 新增 2024-01-09 22:00:00 格式的测试示例

上级 c0027983
...@@ -66,7 +66,10 @@ export function testDate() : Result { ...@@ -66,7 +66,10 @@ export function testDate() : Result {
// final millisecond (month boundary) // final millisecond (month boundary)
expect(new Date(2016, 1, 29, 23, 59, 59, 999).getDate()).toEqual(29); expect(new Date(2016, 1, 29, 23, 59, 59, 999).getDate()).toEqual(29);
// subsequent millisecond (month boundary) // subsequent millisecond (month boundary)
expect(new Date(2016, 1, 29, 23, 59, 59, 1000).getDate()).toEqual(1); expect(new Date(2016, 1, 29, 23, 59, 59, 1000).getDate()).toEqual(1);
expect(Date.parse("2024-01-09 22:00:00")).toEqual(1704808800000);
}) })
test('getDay', () => { test('getDay', () => {
const birthday = new Date('August 19, 1975 23:15:30'); const birthday = new Date('August 19, 1975 23:15:30');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册