diff --git a/.github/workflows/release-e2e-workflow-template.yml b/.github/workflows/release-e2e-workflow-template.yml index 33ad16985..6b1d06e55 100644 --- a/.github/workflows/release-e2e-workflow-template.yml +++ b/.github/workflows/release-e2e-workflow-template.yml @@ -115,19 +115,19 @@ jobs: command: ${{ inputs.test-command }} wait-on: 'http://localhost:5601' # Screenshots are only captured on failure, will change this once we do visual regression tests - - uses: actions/upload-artifact@v1 + - uses: actions/upload-artifact@v4 if: failure() with: name: cypress-screenshots path: cypress-test/cypress/screenshots # Test run video was always captured, so this action uses "always()" condition - - uses: actions/upload-artifact@v1 + - uses: actions/upload-artifact@v4 if: always() with: name: cypress-videos path: cypress-test/cypress/videos # Test reports was always captured, so this action uses "always()" condition - - uses: actions/upload-artifact@v1 + - uses: actions/upload-artifact@v4 if: always() with: name: cypress-results diff --git a/cypress/integration/plugins/reports-dashboards/04-download.spec.js b/cypress/integration/plugins/reports-dashboards/04-download.spec.js index ff2d0c60b..64fcea9d0 100644 --- a/cypress/integration/plugins/reports-dashboards/04-download.spec.js +++ b/cypress/integration/plugins/reports-dashboards/04-download.spec.js @@ -31,6 +31,10 @@ describe('Cypress', () => { cy.visit(`${BASE_PATH}/app/reports-dashboards#/`, { waitForGetTenant: true, }); + cy.intercept('GET', `${BASE_PATH}/api/reporting/generateReport/*`).as( + 'generateReport' + ); + cy.location('pathname', { timeout: TIMEOUT }).should( 'include', '/reports-dashboards' @@ -40,9 +44,7 @@ describe('Cypress', () => { cy.get('[id="landingPageOnDemandDownload"]') .contains('PDF') .click({ force: true }); - cy.get('.euiToastHeader__title') - .contains('Successfully generated report') - .should('exist'); + cy.wait('@generateReport').its('response.statusCode').should('eq', 200); }); it('Download pdf from in-context menu', () => {