mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-14 23:21:35 +00:00
Knip flagged remark-gfm as unused and date-fns as imported-but-undeclared, so drop remark-gfm (which prunes its transitive markdown subtree from the lockfile) and declare date-fns, which keyExpiryUtils.ts imports but only received transitively. Also delete the dead memory/components/index.tsx barrel, since nothing imports it once the page pulls MemoryView from its module directly Knip itself could not run: its Playwright plugin imports every config referenced by a --config flag in package.json scripts, and migration.serverRootPath.config.ts threw at import time when SERVER_ROOT_PATH was unset. Move that guard into a config-specific globalSetup so importing the config is side-effect-free; the check still fires loudly before any test runs when the prefix is missing
30 lines
1 KiB
TypeScript
30 lines
1 KiB
TypeScript
import { defineConfig, devices } from "@playwright/test";
|
|
|
|
/**
|
|
* App Router migration smoke under a non-root mount. Boot the proxy with the same
|
|
* SERVER_ROOT_PATH (e.g. SERVER_ROOT_PATH=/litellm) and a UI built for it before
|
|
* running. globalSetup logs in at `${SERVER_ROOT_PATH}/ui/login` so the admin
|
|
* storage state is valid under the prefix.
|
|
*/
|
|
export default defineConfig({
|
|
testDir: "./tests/migration",
|
|
testMatch: ["migratedPages.spec.ts"],
|
|
fullyParallel: true,
|
|
forbidOnly: !!process.env.CI,
|
|
retries: process.env.CI ? 2 : 0,
|
|
workers: process.env.CI ? 1 : undefined,
|
|
reporter: "list",
|
|
use: {
|
|
baseURL: "http://localhost:4000",
|
|
trace: "on-first-retry",
|
|
actionTimeout: 15 * 1000,
|
|
navigationTimeout: 30 * 1000,
|
|
launchOptions: {
|
|
slowMo: process.env.SLOWMO ? parseInt(process.env.SLOWMO, 10) || 0 : 0,
|
|
},
|
|
},
|
|
projects: [{ name: "chromium", use: { ...devices["Desktop Chrome"] } }],
|
|
timeout: 3 * 60 * 1000,
|
|
expect: { timeout: 10 * 1000 },
|
|
globalSetup: require.resolve("./migration.serverRootPath.globalSetup"),
|
|
});
|