Skip to content

Commit

Permalink
fix domain rbac playwright failure
Browse files Browse the repository at this point in the history
  • Loading branch information
shrushti2000 committed Feb 23, 2025
1 parent e1e3ec6 commit 29a3d13
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -516,20 +516,17 @@ test.describe('Domains Rbac', () => {

// Add domain role to the user
await visitUserProfilePage(page, user1.responseData.name);
await page
.getByTestId('user-profile')
.locator('.ant-collapse-expand-icon')
.click();
await page.getByTestId('edit-roles-button').click();

await page
.getByTestId('select-user-roles')
.getByLabel('Select roles')
.click();
await page.locator('[data-testid="user-profile-edit-popover"]').isVisible();
await page.locator('input[role="combobox"]').nth(1).click();
await page.waitForSelector('[data-testid="profile-edit-roles-select"]');
await page.getByText('Domain Only Access Role').click();
await page.click('body');
const patchRes = page.waitForResponse('/api/v1/users/*');
await page.getByTestId('inline-save-btn').click();
await page
.locator('[data-testid="user-profile-edit-roles-save-button"]')
.click();
await patchRes;
await afterAction();
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ const UserProfileRoles = ({
showSearch
aria-label="Roles"
className="w-full"
data-testid="persona-edit-roles"
data-testid="profile-edit-roles-select"
dropdownMatchSelectWidth={false}
filterOption={handleSearchFilterOption}
loading={isLoading}
Expand Down

0 comments on commit 29a3d13

Please sign in to comment.