litellm/tests/e2e
ryan-crabbe-berri 47b3d07c2d
feat(ui): persist mcp servers tabs, filters, open server and tool state in the URL (#41471)
* feat(ui): persist mcp state in the URL

The MCP Servers page keeps its tab, team, access group, search and sort
filters, the open server and its tab, the selected tool and tool search,
the toolsets table sort and page, the Connect client tab and the
submissions filters in the query string, so reloads, shared links and
back/forward restore the same view.

The open server is resolved from the full server list, so a deep link
opens it even when the current filters hide it and an unknown id shows
the list instead of an "Unnamed Server" placeholder. The fill_env_vars
deep link and the tools/edit OAuth return now go through nuqs instead of
window.history, and the OAuth return writes server and server_tab.

MCPConnect now defines its code block and step card at module level and
renders the tab bodies as plain elements, so switching the URL-backed
client tab (or copying a snippet) no longer remounts them and resets the
x-mcp-servers toggle.

* fix(ui): address review on mcp url state

A stale edit OAuth state no longer overrides the server in the URL and is dropped when its server is gone. The empty state now says no server matches when filters hide every server. Admin tab gates share one flag. Tests cover every page tab value, clearing detail keys on Back, the tool result tag, malformed stored OAuth state and the http client tab.

* chore(ui): prune stale eslint suppressions for mcp servers

* fix(ui): keep mcp tab links while the user role loads

Every page and server tab is now a valid URL value. Visibility is resolved at
render against the role, the same way the Models page does it, so a link to an
admin-only tab is no longer stripped while /management/v1/users/me is still
loading. A role that cannot see a tab gets All Servers or Overview and the link
stays in the URL.

Renames the network tab slug to network-settings to match the tab value, and
adds connections and user-credentials for the Live Connections and User
Credentials tabs.

* test(ui): cover mcp url state for role loading, gated tabs and edge links

Adds hook tests for the tab resolver, role gates, OAuth restore and the
fill_env_vars link, plus page-level tests for unknown servers, literal search
text, a bare URL that writes nothing and an internal user who never loads the
semantic filter settings.

* test(ui): make the mcp url state absence checks able to fail

The non-admin settings link test read URL writes before nuqs flushed them, so
it passed on code that stripped the param. It now rerenders as an admin and
expects Settings. The bare URL test gains a follow-up write so an unwired
listener cannot pass it.

* test(ui): add an e2e spec for mcp servers url state

Covers the role matrix for gated page and server tab links, links that
arrive before the role, a logged-out link through login, a failed role
request, and Back and Forward for an open server and a picked tool.

* test(ui): match the mcp e2e liveness requests by suffix so the spec runs under a root path

* fix(ui): skip the history entry when the selected mcp tool is picked again

* test(ui): pin replace history for mcp server filters, tool search and submission search

* refactor(ui): keep the mcp servers component under the complexity limit

The null-guarded role checks pushed MCPServers to a complexity of 21, one over
the lint limit, which took the dashboard complexity budget to 141 of 140.
Moving them into a module-level roleAccess helper keeps the same results.

* test(ui): pin the live connections tab fallback for an org admin

An org admin passes the admin check but not the proxy admin tier check, so a
connections link must show All Servers, keep the param and never request live
sessions. Kills the mutants that open the gate to any role or to every admin.

* test(ui): move the mcp url state cases into integration test files

The URL state cases render MCPServers and MCPToolsViewer with their real child
components and stub only the network, so they belong in the integration tier
per the dashboard testing guide. The unit files keep the existing cases.

---------

Co-authored-by: Yuneng Jiang <yuneng@berri.ai>
2026-11-26 20:55:15 -08:00
..
a2a test(a2a): replace the third-party agent e2e test with an integration test (#49541) 2026-10-31 18:59:04 -07:00
access_control test(e2e): move the Gemini Flash alias off the retired gemini-2.5-flash (#52823) 2026-11-19 20:47:54 -08:00
batches fix(proxy): count Vertex and Bedrock batch input tokens (#53257) 2026-11-22 18:02:42 -08:00
claude_code test(e2e): move the Claude Code matrix to Opus, Sonnet and Haiku 5.5, Fable 5.2 and GPT-6 (#54305) 2026-11-25 01:47:03 +00:00
cli_harness test(e2e): share the coding-CLI harness between suites (#49370) 2026-11-02 13:50:56 -08:00
codex test(e2e): add a codex row that calls an mcp tool whose name is over 64 characters (#49826) 2026-11-24 16:28:11 -08:00
coverage_registry test(responses-bridge): cover multi-turn GPT-6.2 prompt caching on OpenAI and Bedrock Mantle (#54361) 2026-11-25 11:39:57 +00:00
gateway test(e2e): move the Gemini Flash alias off the retired gemini-2.5-flash (#52823) 2026-11-19 20:47:54 -08:00
guardrails test(e2e): move the Gemini Flash alias off the retired gemini-2.5-flash (#52823) 2026-11-19 20:47:54 -08:00
llm_translation test(responses-bridge): cover multi-turn GPT-6.2 prompt caching on OpenAI and Bedrock Mantle (#54361) 2026-11-25 11:39:57 +00:00
logging test(e2e): move the Gemini Flash alias off the retired gemini-2.5-flash (#52823) 2026-11-19 20:47:54 -08:00
management test: update stale integration and e2e expectations for intended changes (#53940) 2026-11-23 14:27:20 -08:00
mcp test(e2e): retire the quiet_stack lock and batch the claude_code model registration (#49984) 2026-11-04 09:55:53 -08:00
migrations refactor(helm)!: connect both charts to a separately deployed Lens (#49169) 2026-10-30 02:29:44 +00:00
other feat(auth): decide key and JWT authentication in a Rust core (#51374) 2026-11-17 14:07:47 +09:00
perf test(perf): raise the idle worker RSS budget (#53919) 2026-11-24 08:27:17 -08:00
quota_management test(e2e): move the Gemini Flash alias off the retired gemini-2.5-flash (#52823) 2026-11-19 20:47:54 -08:00
router test(e2e): retire the quiet_stack lock and batch the claude_code model registration (#49984) 2026-11-04 09:55:53 -08:00
ui feat(ui): persist mcp servers tabs, filters, open server and tool state in the URL (#41471) 2026-11-26 20:55:15 -08:00
AGENTS.md test(responses-bridge): cover multi-turn GPT-6.2 prompt caching on OpenAI and Bedrock Mantle (#54361) 2026-11-25 11:39:57 +00:00
conftest.py test(e2e): remove the secret manager suite (#51241) 2026-11-11 22:56:36 +00:00
CONTRIBUTING.md fix(router): make the constructor stub work for mypy and guard it in CI (#50354) 2026-11-22 21:25:00 +00:00
e2e_config.py test(responses-bridge): cover multi-turn GPT-6.2 prompt caching on OpenAI and Bedrock Mantle (#54361) 2026-11-25 11:39:57 +00:00
e2e_db.py
e2e_http.py test(e2e): get_text_external accepts JSON next to text so a pod-log error reads as the Kubernetes Status, not a 406 (#47150) 2026-10-17 13:25:29 -07:00
e2e_metadata.py test(e2e): add enum values, auto-discovering label gates and secret hiding for e2e metadata (#44949) 2026-10-06 17:03:35 -07:00
fixture_bundle.py test: add strict stateless provider replay identity 2026-09-14 16:55:43 -07:00
fixture_canonical.py feat(e2e): key the provider cache per test and mount Bedrock behind it 2026-09-16 02:15:46 -07:00
fixture_mode.py fix(e2e): own a shared fixture's deployment by the fixture's node, not the first test 2026-09-16 17:35:05 -07:00
fixture_profile.py test: preserve strict replay numeric spelling 2026-09-14 17:11:56 -07:00
idp.py test(e2e): add enum values, auto-discovering label gates and secret hiding for e2e metadata (#44949) 2026-10-06 17:03:35 -07:00
idp_realm.json test(e2e): harden JWT fixtures and cover management lifecycles 2026-09-11 16:36:12 -07:00
junit_properties.py test(e2e): move the harness self-tests out of tests/e2e (#45172) 2026-10-07 22:20:02 +00:00
lifecycle.py test(e2e): add enum values, auto-discovering label gates and secret hiding for e2e metadata (#44949) 2026-10-06 17:03:35 -07:00
memory_readings.py test(perf): report unanswered RSS captures as probe incomplete, not worker death (#52867) 2026-11-20 17:15:30 +00:00
models.py feat(usage-export): include key and user metadata objects in daily activity export rows (#49360) 2026-11-20 03:58:01 +00:00
otel_client.py fix(e2e): restore main qualification across providers and UI (#49763) 2026-11-03 20:38:47 +00:00
PROVIDER_CACHE.md test(e2e): move the harness self-tests out of tests/e2e (#45172) 2026-10-07 22:20:02 +00:00
provider_cache.py fix(e2e): bind provider-cache recordings to the deployment's test, not the serving process 2026-09-16 17:08:17 -07:00
provider_cache_redis.py fix(e2e): restore main qualification across providers and UI (#49763) 2026-11-03 20:38:47 +00:00
provider_cache_routing.py revert(e2e): unmount Gemini, its api_base means two things 2026-09-16 08:37:25 -07:00
provider_edge.py test(e2e): record steps for raw transport calls and poll helpers (#45150) 2026-10-07 15:21:26 -07:00
provider_edge_bedrock.py fix(bedrock)!: replay redacted_thinking on Converse and keep its data as Claude's own string (#46532) 2026-10-14 19:08:14 -07:00
proxy_client.py test(e2e): retire the quiet_stack lock and batch the claude_code model registration (#49984) 2026-11-04 09:55:53 -08:00
pytest.ini test(e2e): remove the secret manager suite (#51241) 2026-11-11 22:56:36 +00:00
transport.py test(e2e): record steps for raw transport calls and poll helpers (#45150) 2026-10-07 15:21:26 -07:00