From 59e097fabea8ed88c8f5d1a6b87bc783d119a74e Mon Sep 17 00:00:00 2001 From: Antoine du Hamel Date: Tue, 8 Aug 2023 18:01:53 +0200 Subject: [PATCH] e2e: fix race condition in transloadit test (#4616) --- e2e/cypress/integration/dashboard-transloadit.spec.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/e2e/cypress/integration/dashboard-transloadit.spec.ts b/e2e/cypress/integration/dashboard-transloadit.spec.ts index 9ac76c8c6..94f03454f 100644 --- a/e2e/cypress/integration/dashboard-transloadit.spec.ts +++ b/e2e/cypress/integration/dashboard-transloadit.spec.ts @@ -364,7 +364,6 @@ describe('Dashboard with Transloadit', () => { it('should complete on retry', () => { cy.get('@file-input').selectFile(['cypress/fixtures/images/cat.jpg', 'cypress/fixtures/images/traffic.jpg'], { force: true }) - cy.get('.uppy-StatusBar-actionBtn--upload').click() cy.intercept('POST', 'https://transloaditstatus.com/client_error', { statusCode: 200, @@ -376,7 +375,9 @@ describe('Dashboard with Transloadit', () => { { statusCode: 500, body: {} }, ).as('failedAssemblyCreation') + cy.get('.uppy-StatusBar-actionBtn--upload').click() cy.wait('@failedAssemblyCreation') + cy.get('button[data-cy=retry]').click() cy.wait(['@assemblies', '@resumable'])