diff --git a/.cypress/integration/channels.spec.js b/.cypress/integration/channels.spec.js index f0fd65b6..65a1d68f 100644 --- a/.cypress/integration/channels.spec.js +++ b/.cypress/integration/channels.spec.js @@ -98,7 +98,7 @@ describe('Test create channels', () => { cy.wait(delay); cy.get( '[data-test-subj="create-recipient-group-modal-create-button"]' - ).click(); + ).click({ force: true }); cy.contains('successfully created.').should('exist'); cy.get('[data-test-subj="create-channel-create-button"]').click(); @@ -135,7 +135,7 @@ describe('Test create channels', () => { ); cy.get( '[data-test-subj="create-ses-sender-modal-create-button"]' - ).click(); + ).click({ force: true }); cy.contains('successfully created.').should('exist'); // custom data-test-subj does not work on combo box @@ -182,7 +182,7 @@ describe('Test create channels', () => { 'arn:aws:iam::012345678901:role/NotificationsSNSRole' ); - cy.get('[data-test-subj="create-channel-create-button"]').click(); + cy.get('[data-test-subj="create-channel-create-button"]').click({ force: true }); cy.contains('successfully created.').should('exist'); }); }); diff --git a/.cypress/support/commands.js b/.cypress/support/commands.js index 994f8589..58c8e439 100644 --- a/.cypress/support/commands.js +++ b/.cypress/support/commands.js @@ -83,6 +83,11 @@ Cypress.Commands.add('createTestEmailChannel', () => { }); Cypress.Commands.add('deleteAllConfigs', () => { + cy.request({ + method: 'POST', + url: `${Cypress.env('opensearch')}/_refresh` + }); + cy.request({ method: 'GET', url: `${Cypress.env('opensearch')}${API.CONFIGS_BASE}`,