mirror of
https://github.com/openclaw/openclaw.git
synced 2026-06-03 16:34:07 +00:00
test(ci): isolate infra vitest lane
This commit is contained in:
@@ -120,6 +120,15 @@ function expectThreadedNonIsolatedRunner(config: {
|
||||
expect(normalizeConfigPath(testConfig.runner)).toBe("test/non-isolated-runner.ts");
|
||||
}
|
||||
|
||||
function expectThreadedIsolatedRunner(config: {
|
||||
test?: { pool?: unknown; isolate?: unknown; runner?: unknown };
|
||||
}) {
|
||||
const testConfig = requireTestConfig(config);
|
||||
expect(testConfig.pool).toBe("threads");
|
||||
expect(testConfig.isolate).toBe(true);
|
||||
expect(testConfig.runner).toBeUndefined();
|
||||
}
|
||||
|
||||
describe("resolveVitestIsolation", () => {
|
||||
it("aliases private QA plugin SDK subpaths for source tests only", () => {
|
||||
for (const subpath of PRIVATE_PLUGIN_SDK_SUBPATHS) {
|
||||
@@ -362,7 +371,6 @@ describe("scoped vitest configs", () => {
|
||||
defaultExtensionProvidersConfig,
|
||||
defaultExtensionSignalConfig,
|
||||
defaultExtensionSlackConfig,
|
||||
defaultInfraConfig,
|
||||
defaultAutoReplyConfig,
|
||||
defaultAutoReplyCoreConfig,
|
||||
defaultAutoReplyTopLevelConfig,
|
||||
@@ -379,6 +387,7 @@ describe("scoped vitest configs", () => {
|
||||
expectThreadedNonIsolatedRunner(defaultCommandsConfig);
|
||||
|
||||
expectThreadedNonIsolatedRunner(defaultUiConfig);
|
||||
expectThreadedIsolatedRunner(defaultInfraConfig);
|
||||
});
|
||||
|
||||
it("keeps the process lane off the openclaw runtime setup", () => {
|
||||
|
||||
@@ -6,6 +6,7 @@ export function createInfraVitestConfig(env?: Record<string, string | undefined>
|
||||
dir: "src",
|
||||
env,
|
||||
exclude: boundaryTestFiles,
|
||||
isolate: true,
|
||||
name: "infra",
|
||||
passWithNoTests: true,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user