/** * The per-test timeout for Core's import-safety tests, and only those. * * Each of these tests proves that importing a module does nothing (no I/O, no connection, no output) * by performing a cold dynamic `import()` of a large Core source graph inside the test body. Vitest * transforms and evaluates that whole graph on demand, and that work is CPU-bound. An ordinary test * file's own top-level imports run before its tests start and fall under no per-test timeout; these * deliberately do not, so the cost lands inside Vitest's default 5-second test timeout. * * Alone they take about 0.7–1.2 s. During a full `pnpm verify`, Turbo runs every package's suite at * once and the CPU is saturated. Reproduced locally (six cores, Core's suite alongside five other * packages' suites), the same tests took 3.0–5.4 s, and so timed out intermittently. * * 30 seconds is about five times the slowest time measured under load, which leaves room for slower * shared CI runners. It matches the repository's integration-test timeout. It is still bounded, so a * module that genuinely hangs while being imported, for example on a network call, still fails. The * assertions themselves are unchanged: these tests fail on what an import does, never on speed. */ export const IMPORT_SAFETY_TEST_TIMEOUT_MS = 30_000;