From 5ff338eedf2a89ee8f25187bc97b41b46766d3b2 Mon Sep 17 00:00:00 2001 From: Erik Jan de Wit Date: Thu, 3 Feb 2022 15:13:39 +0100 Subject: [PATCH] small fix (#2001) * small fix * fixes delete --- .../manage/realm_settings/RealmSettingsPage.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/cypress/support/pages/admin_console/manage/realm_settings/RealmSettingsPage.ts b/cypress/support/pages/admin_console/manage/realm_settings/RealmSettingsPage.ts index c29866dde4..7aa3ff9462 100644 --- a/cypress/support/pages/admin_console/manage/realm_settings/RealmSettingsPage.ts +++ b/cypress/support/pages/admin_console/manage/realm_settings/RealmSettingsPage.ts @@ -626,7 +626,9 @@ export default class RealmSettingsPage { "This action will permanently delete the policy Test. This cannot be undone." ); cy.findByTestId(this.modalConfirm).contains("Delete"); - cy.get(this.deleteDialogCancelBtn).contains("Cancel").click(); + cy.get(this.deleteDialogCancelBtn) + .contains("Cancel") + .click({ force: true }); cy.get("table").should("be.visible").contains("td", "Test"); } @@ -634,7 +636,7 @@ export default class RealmSettingsPage { this.listingPage.searchItem("Test", false); this.listingPage.clickRowDetails("Test").clickDetailMenu("Delete"); cy.findByTestId(this.modalConfirm).contains("Delete"); - cy.findByTestId(this.modalConfirm).click(); + cy.findByTestId(this.modalConfirm).click({ force: true }); cy.get(this.alertMessage).should("be.visible", "Client profile deleted"); cy.get("table").should("not.have.text", "Test"); } @@ -820,7 +822,7 @@ export default class RealmSettingsPage { }); cy.get(this.moreDrpDwnItems).click(); cy.findByTestId(this.modalConfirm).contains("Delete"); - cy.findByTestId(this.modalConfirm).click(); + cy.findByTestId(this.modalConfirm).click({ force: true }); cy.get(this.alertMessage).should("be.visible", "Client profile deleted"); cy.get("table").should("not.have.text", "Edit"); } @@ -1011,9 +1013,9 @@ export default class RealmSettingsPage { addClientScopes() { cy.findByTestId(this.selectScopeButton).click(); - cy.get(".pf-c-table__check > input[name=checkrow0]").click(); - cy.get(".pf-c-table__check > input[name=checkrow1]").click(); - cy.get(".pf-c-table__check > input[name=checkrow2]").click(); + cy.get("input[name=checkrow0]").click(); + cy.get("input[name=checkrow1]").click(); + cy.get("input[name=checkrow2]").click(); cy.findByTestId(this.modalConfirm).contains("Add").click(); } @@ -1108,7 +1110,7 @@ export default class RealmSettingsPage { "This action will permanently delete client-scopes. This cannot be undone." ); cy.findByTestId(this.modalConfirm).contains("Delete"); - cy.findByTestId(this.modalConfirm).click(); + cy.findByTestId(this.modalConfirm).click({ force: true }); cy.get('h6[class*="kc-emptyConditions"]').should( "have.text", "No conditions configured"