mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-12 07:20:45 +00:00
refactor(test): extract shared gateway hook and vitest scoped config helpers
This commit is contained in:
@@ -1,15 +1,3 @@
|
||||
import { defineConfig } from "vitest/config";
|
||||
import baseConfig from "./vitest.config.ts";
|
||||
import { createScopedVitestConfig } from "./vitest.scoped-config.ts";
|
||||
|
||||
const base = baseConfig as unknown as Record<string, unknown>;
|
||||
const baseTest = (baseConfig as { test?: { exclude?: string[] } }).test ?? {};
|
||||
const exclude = baseTest.exclude ?? [];
|
||||
|
||||
export default defineConfig({
|
||||
...base,
|
||||
test: {
|
||||
...baseTest,
|
||||
include: ["src/gateway/**/*.test.ts"],
|
||||
exclude,
|
||||
},
|
||||
});
|
||||
export default createScopedVitestConfig(["src/gateway/**/*.test.ts"]);
|
||||
|
||||
Reference in New Issue
Block a user