test(web): build memo stats fixtures at local noon (#6584)

This commit is contained in:
Divya
2026-11-18 05:46:25 -08:00
committed by GitHub
parent 43a3feca7a
commit ce572cc146
+3 -1
View File
@@ -29,8 +29,10 @@ import { State } from "@/types/proto/api/common_pb";
const wrapper = ({ children }: { children: ReactNode }) => children as never;
// The hook buckets by the viewer's local calendar day, so build fixtures at
// local noon: UTC midnight is the previous day in time zones west of UTC.
const ts = (year: number, month: number, day: number) => ({
seconds: BigInt(Math.floor(Date.UTC(year, month - 1, day) / 1000)),
seconds: BigInt(Math.floor(new Date(year, month - 1, day, 12).getTime() / 1000)),
nanos: 0,
});