The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
test(ui): find the max_budget checkbox by its new label
ryan-crabbe-berrid3f060782096
diff --git a/ui/litellm-dashboard/src/components/Settings/AdminSettings/UISettings/TeamAdminEditableFieldsSettings.test.tsx b/ui/litellm-dashboard/src/components/Settings/AdminSettings/UISettings/TeamAdminEditableFieldsSettings.test.tsxindex 2e1a8e9fd36..602b3b02797 100644--- a/ui/litellm-dashboard/src/components/Settings/AdminSettings/UISettings/TeamAdminEditableFieldsSettings.test.tsx+++ b/ui/litellm-dashboard/src/components/Settings/AdminSettings/UISettings/TeamAdminEditableFieldsSettings.test.tsx@@ -21,6 +21,7 @@ vi.mock("@/app/(dashboard)/hooks/uiSettings/useUpdateUISettings", () => ({}));const TPM_LABEL = "Tokens per minute Limit (TPM)";+const MAX_BUDGET_LABEL = "Max Budget (USD)";const mockSettings = (supported: readonly string[], enabled: readonly string[]) =>mockUseUISettings.mockReturnValue({@@ -80,7 +81,7 @@ describe("TeamAdminEditableFieldsSettings", () => {expect(screen.getByText("Team admin editable fields")).toBeInTheDocument();expect(screen.getByText("1 field enabled")).toBeInTheDocument();expect(screen.getByText("Fields a team admin may change")).toBeInTheDocument();- expect(screen.getByRole("checkbox", { name: "max_budget" })).not.toBeChecked();+ expect(screen.getByRole("checkbox", { name: MAX_BUDGET_LABEL })).not.toBeChecked();expect(screen.getByRole("checkbox", { name: TPM_LABEL })).toBeChecked();expect(saveButton()).toBeDisabled();});@@ -90,9 +91,9 @@ describe("TeamAdminEditableFieldsSettings", () => {const mutate = mockSave({});renderWithProviders(<TeamAdminEditableFieldsSettings />);- fireEvent.click(screen.getByRole("checkbox", { name: "max_budget" }));+ fireEvent.click(screen.getByRole("checkbox", { name: MAX_BUDGET_LABEL }));- expect(screen.getByRole("checkbox", { name: "max_budget" })).toBeChecked();+ expect(screen.getByRole("checkbox", { name: MAX_BUDGET_LABEL })).toBeChecked();expect(mutate).not.toHaveBeenCalled();fireEvent.click(saveButton());