mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-12 21:53:00 -06:00
896592b747
A vitest/vite type bump made inferred creator return types reach
vite-internal names (TS4058/TS4082), failing check-test-types repo-wide.
Annotate the scoped/extension config roots and the spread-rebuilding
creators with ViteUserConfig; also drop an unused workflow read, mutating
sorts, and an untyped record index left by 1f591bba56.
31 lines
874 B
TypeScript
31 lines
874 B
TypeScript
// Vitest runtime config config wires the runtime config test shard.
|
|
import type { ViteUserConfig } from "vitest/config";
|
|
import { createScopedVitestConfig } from "./vitest.scoped-config.ts";
|
|
|
|
export function createRuntimeConfigVitestConfig(
|
|
env?: Record<string, string | undefined>,
|
|
): ViteUserConfig {
|
|
const config = createScopedVitestConfig(["src/config/**/*.test.ts"], {
|
|
dir: "src",
|
|
env,
|
|
includeOpenClawRuntimeSetup: false,
|
|
name: "runtime-config",
|
|
passWithNoTests: true,
|
|
// Native SQLite handles can abort V8 when threaded workers tear down.
|
|
// Forks keep database lifetimes inside a disposable process.
|
|
pool: "forks",
|
|
});
|
|
return {
|
|
...config,
|
|
test: {
|
|
...config.test,
|
|
sequence: {
|
|
...config.test?.sequence,
|
|
groupOrder: 3,
|
|
},
|
|
},
|
|
};
|
|
}
|
|
|
|
export default createRuntimeConfigVitestConfig();
|