litellm/tests/e2e/ui/fixtures/menuMappings.ts
ryan-crabbe-berri 0fcaadf11c
test(e2e): move Admin UI Playwright suite to tests/e2e/ui (#34196)
Relocates ui/litellm-dashboard/e2e_tests to tests/e2e/ui so all end to end
suites live under tests/e2e. The suite stays in TypeScript and becomes a
self-contained npm package with its own package.json, lockfile and tsconfig
instead of leaning on the dashboard's toolchain; the dashboard drops its
@playwright/test dependency, e2e scripts and knip/vitest/tsconfig carve-outs.

CI paths follow the move: both CircleCI jobs (main e2e and the
SERVER_ROOT_PATH migration smoke) and the test_server_root_path workflow now
install and run Playwright from tests/e2e/ui, with the node cache keyed on
both lockfiles. classify_changes.sh treats tests/e2e/ui as client so spec
edits keep skipping backend jobs. The suite's mock LLM fixture is excluded
from the e2e basedpyright zero-error gate in pyrightconfig.json since it
belongs to the TS suite, not the typed Python harness.
2026-07-22 19:43:10 +00:00

39 lines
1.2 KiB
TypeScript

import { Page } from "./pages";
/**
* Maps sidebar menu item labels to their corresponding page enum values.
* This mapping is for the admin role.
*/
export const menuLabelToPage: Record<string, Page> = {
"Virtual Keys": Page.ApiKeys,
Playground: Page.LlmPlayground,
Models: Page.Models,
"Models + Endpoints": Page.Models,
Usage: Page.NewUsage,
Teams: Page.Teams,
"Internal Users": Page.Users,
"Internal User": Page.Users, // Legacy label support
Organizations: Page.Organizations,
"API Reference": Page.ApiRef,
"AI Hub": Page.ModelHubTable,
"Model Hub": Page.ModelHubTable,
Logs: Page.Logs,
Guardrails: Page.Guardrails,
// Settings submenu items
"Router Settings": Page.RouterSettings,
"Logging & Alerts": Page.LoggingAndAlerts,
"Admin Settings": Page.AdminPanel,
"Cost Tracking": Page.CostTracking,
"UI Theme": Page.UiTheme,
// Experimental submenu items
"Response Cache": Page.Caching,
Caching: Page.Caching, // Legacy label support
Prompts: Page.Prompts,
Budgets: Page.Budgets,
"API Playground": Page.TransformRequest,
"Tag Management": Page.TagManagement,
"Old Usage": Page.Usage,
// Tools submenu items
"MCP Servers": Page.McpServers,
"Vector Stores": Page.VectorStores,
};