UNPKG

siegel

Version:

Web application development ecosystem

1 lines 428 B
import e from"./index.js";describe("common/date/parse",()=>{let t=new Date(1),s=t.getFullYear(),o=t.getDay(),a=t.getMonth()+1,c=t.getDate(),n=t.getHours(),g=t.getMinutes(),i=t.getSeconds(),r=t.getMilliseconds();test("parse",()=>{expect(e(t)).toEqual({month:a,date:c,hours:n,minutes:g,seconds:i,milliseconds:r,year:s,day:o})}),test("parse zeroing",()=>{expect(e(t,!0)).toMatchObject({milliseconds:"0001",seconds:"00",day:o})})});