test: add CRM admin Playwright coverage - #10
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ec8b29cb20
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| await page.getByPlaceholder("Search users").fill("") | ||
| await page.getByLabel("Clear filter").click() | ||
| await page.getByRole("combobox").first().selectOption("status") |
There was a problem hiding this comment.
Scope the filter combobox locator
On resource pages the generated AdminShell renders its tenant selector before the grid, so getByRole("combobox").first() targets the header tenant dropdown, not the filter-field dropdown. In the searches and filters the resource list test this makes selectOption("status") fail because the tenant selector only contains tenant options; scope the locator to the grid/filter controls or give the filter select an accessible label.
Useful? React with 👍 / 👎.
Summary
Closes #4
Tests
Note: I did not run the full browser suite because it requires a generated Next.js app server at the configured base URL.