wait for requests on add menu item page (#2540)
This commit is contained in:
parent
7fd2eb2a2c
commit
0c1fa47c35
2 changed files with 7 additions and 1 deletions
|
@ -58,6 +58,9 @@ describe("Tests for menu navigation", () => {
|
|||
const itemName = `${startsWith}${faker.datatype.number()}`;
|
||||
let selectedItem;
|
||||
|
||||
cy.addAliasToGraphRequest("SearchCategories")
|
||||
.addAliasToGraphRequest("SearchPages")
|
||||
.addAliasToGraphRequest("SearchCollections");
|
||||
createNewMenuItem({
|
||||
menuId: menu.id,
|
||||
name: itemName,
|
||||
|
|
|
@ -24,6 +24,9 @@ export function createNewMenuItem({ menuId, name, menuItemType }) {
|
|||
|
||||
return cy
|
||||
.visit(menuDetailsUrl(menuId))
|
||||
.wait("@SearchCollections")
|
||||
.wait("@SearchPages")
|
||||
.wait("@SearchCategories")
|
||||
.get(MENU_DETAILS.createNewMenuItemButton)
|
||||
.click()
|
||||
.get(SHARED_ELEMENTS.dialog)
|
||||
|
@ -52,5 +55,5 @@ export function createNewMenuItem({ menuId, name, menuItemType }) {
|
|||
export const MENU_ITEM_TYPES = {
|
||||
category: "categoryItem",
|
||||
collection: "collectionItem",
|
||||
page: "pageItem"
|
||||
page: "pageItem",
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue