MCPcopy
hub / github.com/date-fns/date-fns / sameTime

Function sameTime

pkgs/core/src/differenceInCalendarDays/test.ts:120–127  ·  view source on GitHub ↗
(t1: Date, t2: Date)

Source from the content-addressed store, hash-verified

118 const HOUR = 1000 * 60 * 60;
119 const MINUTE = 1000 * 60;
120 function sameTime(t1: Date, t2: Date): boolean {
121 return (
122 t1.getHours() === t2.getHours() &&
123 t1.getMinutes() === t2.getMinutes() &&
124 t1.getSeconds() === t2.getSeconds() &&
125 t1.getMilliseconds() === t2.getMilliseconds()
126 );
127 }
128
129 expect(start).not.toBe(undefined);
130 expect(end).not.toBe(undefined);

Callers 1

test.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected