litellm/ui/litellm-dashboard/e2e_tests/tests/internal-user
ryan-crabbe-berri 892838963c
test(e2e): cover Internal User create-key flow when in no teams (#29083)
* test(e2e): cover Internal User create-key flow when in no teams

The seeded e2e-internal-user is in two teams, so the "no team" branch
of the Create Key modal — where the team dropdown must render empty —
was unreachable. Seeds a noteam@test.local user and adds a spec that
logs in fresh, opens the modal, and asserts the dropdown has zero
options.

* test(e2e): harden no-team dropdown assertion + add with-teams counterpart

Replace the one-shot count() check with a settled-empty assertion: wait for
the dropdown's loaded "No teams found" state before asserting zero options,
so the test can't pass on a transient empty frame while the team-options
request is still in flight.

Add internalUserWithTeams.spec.ts as the differential partner; it logs in as
the seeded e2e-internal-user (two team memberships) and asserts the dropdown
lists exactly those teams. Without it, the no-team spec's zero-options
assertion would still pass against a regression that empties the dropdown for
every user.
2026-05-30 00:26:28 -07:00
..
internalUser.spec.ts test(e2e): cover Internal User key modal, team info, key page (#29074) 2026-05-29 14:36:27 -07:00
internalUserNoTeam.spec.ts test(e2e): cover Internal User create-key flow when in no teams (#29083) 2026-05-30 00:26:28 -07:00
internalUserWithTeams.spec.ts test(e2e): cover Internal User create-key flow when in no teams (#29083) 2026-05-30 00:26:28 -07:00