test(sandbox): use focused modules in lightweight suites

This commit is contained in:
Peter Steinberger
2026-02-24 01:45:58 +00:00
parent f0f886ecc4
commit 467666adc7
5 changed files with 14 additions and 23 deletions

View File

@@ -1,20 +1,12 @@
import { beforeAll, describe, expect, it } from "vitest";
let resolveSandboxScope: typeof import("./sandbox.js").resolveSandboxScope;
let resolveSandboxDockerConfig: typeof import("./sandbox.js").resolveSandboxDockerConfig;
let resolveSandboxBrowserConfig: typeof import("./sandbox.js").resolveSandboxBrowserConfig;
let resolveSandboxPruneConfig: typeof import("./sandbox.js").resolveSandboxPruneConfig;
import { describe, expect, it } from "vitest";
import {
resolveSandboxBrowserConfig,
resolveSandboxDockerConfig,
resolveSandboxPruneConfig,
resolveSandboxScope,
} from "./sandbox/config.js";
describe("sandbox config merges", () => {
beforeAll(async () => {
({
resolveSandboxScope,
resolveSandboxDockerConfig,
resolveSandboxBrowserConfig,
resolveSandboxPruneConfig,
} = await import("./sandbox.js"));
});
it("resolves sandbox scope deterministically", () => {
expect(resolveSandboxScope({})).toBe("agent");
expect(resolveSandboxScope({ perSession: true })).toBe("session");