mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 12:07:40 +00:00
test(flaky): harden slow vmFork unit suites
Co-authored-by: Ho Lim <166576253+HOYALIM@users.noreply.github.com>
This commit is contained in:
@@ -12,6 +12,7 @@ const TELEGRAM_TEST_TIMINGS = {
|
||||
mediaGroupFlushMs: 20,
|
||||
textFragmentGapMs: 30,
|
||||
} as const;
|
||||
const TELEGRAM_BOT_IMPORT_TIMEOUT_MS = process.platform === "win32" ? 180_000 : 150_000;
|
||||
let createTelegramBot: typeof import("./bot.js").createTelegramBot;
|
||||
let replySpy: ReturnType<typeof vi.fn>;
|
||||
|
||||
@@ -98,7 +99,7 @@ beforeAll(async () => {
|
||||
({ createTelegramBot } = await import("./bot.js"));
|
||||
const replyModule = await import("../auto-reply/reply.js");
|
||||
replySpy = (replyModule as unknown as { __replySpy: ReturnType<typeof vi.fn> }).__replySpy;
|
||||
});
|
||||
}, TELEGRAM_BOT_IMPORT_TIMEOUT_MS);
|
||||
|
||||
vi.mock("./sticker-cache.js", () => ({
|
||||
cacheSticker: (...args: unknown[]) => cacheStickerSpy(...args),
|
||||
|
||||
Reference in New Issue
Block a user