mirror of
https://github.com/l0ng-ai/openidea.git
synced 2026-11-18 16:08:55 +00:00
fix(e2e): size-check both close button svgs in findUsages-ui (#3834)
The Close Tab button now stacks idle and hovered icons, so the single-svg locator hit Playwright's strict mode. The spec checks every svg each toolbar button renders. Closes #3828 Co-authored-by: Inf1mum <8135225+Inf1mum@users.noreply.github.com>
This commit is contained in:
@@ -69,8 +69,10 @@ for (const theme of ["light", "dark"] as const) {
|
||||
await checkSize(fileIcon);
|
||||
await checkSize(directoryIcon);
|
||||
await checkSize(find.getByRole("status", { name: "Loading", exact: true }));
|
||||
// The close button stacks idle and hovered icons (both 16px); check every svg each button renders.
|
||||
for (const title of ["Stop", "Expand All", "Collapse All", "Close Tab"])
|
||||
await checkSize(find.getByRole("button", { name: title, exact: true }).last().locator("svg"));
|
||||
for (const icon of await find.getByRole("button", { name: title, exact: true }).last().locator("svg").all())
|
||||
await checkSize(icon);
|
||||
|
||||
await page.evaluate(async () => {
|
||||
const path = "/src/ui/iconAppearance.ts";
|
||||
|
||||
Reference in New Issue
Block a user