diff --git a/openmetadata-ui/src/main/resources/ui/cypress/common/Utils/Owner.ts b/openmetadata-ui/src/main/resources/ui/cypress/common/Utils/Owner.ts index 4969d3022b5..81d09ba91fa 100644 --- a/openmetadata-ui/src/main/resources/ui/cypress/common/Utils/Owner.ts +++ b/openmetadata-ui/src/main/resources/ui/cypress/common/Utils/Owner.ts @@ -69,12 +69,20 @@ export const addOwner = ( dataTestId?: string, verifyPatchResponse = true ) => { + interceptURL( + 'GET', + '/api/v1/search/query?q=*&index=team_search_index*', + 'getTeams' + ); interceptURL('GET', '/api/v1/users?*isBot=false*', 'getUsers'); cy.get('[data-testid="edit-owner"]') .scrollIntoView() .click({ waitForAnimations: false }); cy.get("[data-testid='select-owner-tabs']").should('be.visible'); + + verifyResponseStatusCode('@getTeams', 200); // wait for teams to load before switching the tab + cy.get('.ant-tabs [id*=tab-users]') .scrollIntoView() .click({ waitForAnimations: false });