litellm/ui/litellm-dashboard/e2e_tests/tests/settings/adminSettings.spec.ts
Yuneng Jiang 50f002048e
fix(ui): scope the remaining e2e nav lookups to the new sidebar
login and internalUserIdentity used an unscoped "Virtual Keys" text check that now also matches the top-bar breadcrumb, and adminSettings navigated via antd menuitem roles the shadcn nav no longer emits. Scope these to the sidebar's complementary landmark and drive the Settings group by role (expand the button, then click the child link), matching the fixes already applied to the migration and navigation specs
2026-07-10 12:27:34 -07:00

17 lines
787 B
TypeScript

import { test, expect } from "@playwright/test";
import { ADMIN_STORAGE_PATH } from "../../constants";
test.describe("Add Model", () => {
test.use({ storageState: ADMIN_STORAGE_PATH });
test("admin settings test", async ({ page }) => {
await page.goto("/ui");
// "Settings" is a collapsible group (button) in the sidebar; expand it, then
// click the "Admin Settings" child link. Scope to the complementary landmark.
const sidebar = page.getByRole("complementary");
await sidebar.getByRole("button", { name: /Settings/ }).click();
await sidebar.getByRole("link", { name: /Admin Settings/ }).click();
await page.getByRole("tab", { name: "UI Settings" }).click();
await expect(page.getByText("Configuration for UI-specific")).toBeVisible();
});
});