mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-11 10:36:54 +00:00
fix flaky add multiple owner (#22059)
This commit is contained in:
parent
4c1976409a
commit
07fc2fbfa4
@ -263,6 +263,24 @@ export const addMultiOwner = async (data: {
|
||||
{ state: 'detached' }
|
||||
);
|
||||
|
||||
const isClearButtonVisible = await page
|
||||
.locator("[data-testid='select-owner-tabs']")
|
||||
.getByTestId('clear-all-button')
|
||||
.isVisible();
|
||||
|
||||
// If the user is not in the Users tab, switch to it
|
||||
if (!isClearButtonVisible) {
|
||||
await page
|
||||
.locator("[data-testid='select-owner-tabs']")
|
||||
.getByRole('tab', { name: 'Users' })
|
||||
.click();
|
||||
|
||||
await page.waitForSelector(
|
||||
'[data-testid="select-owner-tabs"] [data-testid="loader"]',
|
||||
{ state: 'detached' }
|
||||
);
|
||||
}
|
||||
|
||||
if (clearAll && isMultipleOwners) {
|
||||
await page.click('[data-testid="clear-all-button"]');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user