test: wait for expand form to get loaded before access

Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
This commit is contained in:
Raju Udava
2022-09-26 17:06:49 +05:30
committed by braks
parent 3d8c432d10
commit 11ab351d43
2 changed files with 14 additions and 1 deletions

View File

@@ -56,13 +56,18 @@ let cn = [
];
function openWebhook(index) {
// http://localhost:8080/api/v1/db/meta/tables/md_dx81kkfdso115u/hooks
cy.intercept("GET", "/api/v1/db/meta/tables/*/hooks").as("getHooks");
cy.get(".nc-actions-menu-btn").should("exist").click();
cy.getActiveMenu(".nc-dropdown-actions-menu")
.find(".ant-dropdown-menu-title-content")
.contains("Webhooks")
.click();
cy.get(".nc-hook").eq(index).click();
cy.wait("@getHooks");
cy.get(`.nc-hook:eq(${index})`).should("exist").click();
}
// to be invoked after open