Skip to content

test(playwright): stabilize admin UI auth flows#2533

Merged
crivetimihai merged 2 commits intomainfrom
fix/playwright-admin-login
Jan 28, 2026
Merged

test(playwright): stabilize admin UI auth flows#2533
crivetimihai merged 2 commits intomainfrom
fix/playwright-admin-login

Conversation

@crivetimihai
Copy link
Copy Markdown
Member

@crivetimihai crivetimihai commented Jan 28, 2026

Summary

  • stabilize admin auth flows in Playwright by handling login/change-password transitions and avoiding networkidle hangs
  • update admin UI selectors and navigation expectations to current markup
  • make tool/server UI tests resilient to cached admin pages by asserting via admin JSON endpoints and reducing destructive UI actions

Details

  • login fixture now detects the login form even when the URL is /admin and waits for admin navigation explicitly
  • base navigation uses domcontentloaded for admin pages to avoid long-polling/SSE stalls
  • tools CRUD tests validate create/delete via /admin/tools and /admin/tools/{id}/delete JSON/POST flows
  • server add test targets #add-server-form and validates via /admin/servers list
  • HTMX tool modal tests avoid persisting edits/deletes to shared data while still validating modals and confirmation dialogs

Testing

  • TEST_BASE_URL=http://localhost:8080 PLATFORM_ADMIN_EMAIL=admin@example.com PLATFORM_ADMIN_PASSWORD=changeme123 PLATFORM_ADMIN_NEW_PASSWORD=changeme123 make test-ui-report (32 passed, 8 skipped)

Closes #2136

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
@crivetimihai crivetimihai merged commit e356e7d into main Jan 28, 2026
38 checks passed
@crivetimihai crivetimihai deleted the fix/playwright-admin-login branch January 28, 2026 01:55
@crivetimihai crivetimihai added this to the Release 1.0.0-RC1 milestone Jan 31, 2026
hughhennelly pushed a commit to hughhennelly/mcp-context-forge that referenced this pull request Feb 8, 2026
* test(playwright): handle admin password change

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>

* test(playwright): stabilize admin UI flows

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>

---------

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
Signed-off-by: hughhennnelly <hughhennelly06@gmail.com>
kcostell06 pushed a commit to kcostell06/mcp-context-forge that referenced this pull request Feb 24, 2026
* test(playwright): handle admin password change

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>

* test(playwright): stabilize admin UI flows

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>

---------

Signed-off-by: Mihai Criveti <crivetimihai@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG][TESTING]: Playwright tests not updated to use admin email/password login credentials

1 participant