Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/green-peas-turn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"saleor-dashboard": patch
---

Modify menu tests to ensure the first item in the list is visible before proceeding.
7 changes: 5 additions & 2 deletions playwright/pages/dialogs/addNavigationMenuItemDialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@ export class AddNavigationMenuItemDialog extends BasePage {
}

async selectLinkTypeOption(linkType: string) {
await this.menuLinkType.click();
await this.waitForDOMToFullyLoad();
await expect(async () => {
await this.menuLinkType.click();
await this.waitForDOMToFullyLoad();
await this.menuLinkOptions.first().waitFor({ state: "visible" });
}).toPass();

// Ensure the link type option is visible and select it
const linkTypeOption = this.menuLinkOptions.filter({ hasText: linkType });
Expand Down
Loading