mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-11 17:40:43 +00:00
test: tighten slack thread cache timestamp
This commit is contained in:
@@ -108,13 +108,13 @@ describe("slack sent-thread-cache", () => {
|
||||
logging: { getChildLogger: () => ({ warn: vi.fn() }) },
|
||||
} as never);
|
||||
|
||||
vi.spyOn(Date, "now").mockReturnValue(1_711_406_400_000);
|
||||
recordSlackThreadParticipation("A1", "C123", "1700000000.000002");
|
||||
|
||||
await vi.waitFor(() => expect(register).toHaveBeenCalledTimes(1));
|
||||
expect(register).toHaveBeenCalledWith(
|
||||
"A1:C123:1700000000.000002",
|
||||
expect.objectContaining({ repliedAt: expect.any(Number) }),
|
||||
);
|
||||
expect(register).toHaveBeenCalledWith("A1:C123:1700000000.000002", {
|
||||
repliedAt: 1_711_406_400_000,
|
||||
});
|
||||
|
||||
clearSlackThreadParticipationCache();
|
||||
await expect(
|
||||
|
||||
Reference in New Issue
Block a user