import { describe, expect, it } from "vitest"; import { formatTerminalLogTime } from "./logTime"; describe("formatTerminalLogTime", () => { it("uses the SCUM log clock instead of the browser timezone", () => { expect(formatTerminalLogTime("2026-08-24T01:23:44Z", "[2026.08.23-17.23.44][418]LogSCUM: Global Stats")) .toBe("17:23:44"); }); it("falls back to the event timestamp for generic logs", () => { expect(formatTerminalLogTime("not-a-timestamp")).toBe("时间未知"); }); });