tests: document config mock choice for eager warmup

This commit is contained in:
Mason Huang
2026-04-08 23:26:13 +08:00
committed by Peter Steinberger
parent edc6c13f1f
commit e892518b63

View File

@@ -2,6 +2,7 @@ import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
const loadConfigMock = vi.hoisted(() => vi.fn());
// context.js and command-auth.js still read other config exports at import time, so this test only stubs loadConfig while keeping the rest of the module real.
vi.mock("../config/config.js", async (importOriginal) => {
const actual = await importOriginal<typeof import("../config/config.js")>();
return {