Skip to content

Commit

Permalink
adjust selectors for rbac test
Browse files Browse the repository at this point in the history
  • Loading branch information
nilgaar committed Jan 8, 2025
1 parent 7bc7354 commit 99dbd60
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions e2e-tests/playwright/e2e/plugins/rbac/rbac.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Page, expect, test } from "@playwright/test";
import { Locator, Page, expect, test } from "@playwright/test";
import { Response, Roles } from "../../../support/pages/rbac";
import { UI_HELPER_ELEMENTS } from "../../../support/pageObjects/global-obj";
import {
Expand Down Expand Up @@ -266,8 +266,15 @@ test.describe.serial("Test RBAC", () => {
await page.locator(HOME_PAGE_COMPONENTS.searchBar).fill("Guest User");
await page.click('button[aria-label="Remove"]');
await uiHelper.verifyHeading("Users and groups (1 user, 1 group)");
await uiHelper.clickButton("Next");
await uiHelper.clickButton("Next");
await uiHelper.clickByDataTestId("nextButton-1");
await page.waitForSelector(".permission-policies-form", {
state: "visible",
});
let nextButton2: Locator;
do {
nextButton2 = page.getByTestId("nextButton-2");
} while (nextButton2.all.length > 1);
nextButton2.click();
await uiHelper.clickButton("Save");
await uiHelper.verifyText(
"Role role:default/test-role1 updated successfully",
Expand Down

0 comments on commit 99dbd60

Please sign in to comment.