From: Stephen Smith Date: Thu, 12 May 2022 23:56:13 +0000 (-0400) Subject: 19049: Cypress don't timeout before waitfordom finishes X-Git-Tag: 2.4.1~1^2~4^2~1 X-Git-Url: https://git.arvados.org/arvados-workbench2.git/commitdiff_plain/8e191ecaf0e507dd1d685ca3ebeab954652d8e9e 19049: Cypress don't timeout before waitfordom finishes Arvados-DCO-1.1-Signed-off-by: Stephen Smith --- diff --git a/cypress/support/commands.js b/cypress/support/commands.js index c2d78b54..842c9551 100644 --- a/cypress/support/commands.js +++ b/cypress/support/commands.js @@ -405,7 +405,10 @@ function b64toBlob(b64Data, contentType = '', sliceSize = 512) { // From https://github.com/cypress-io/cypress/issues/7306#issuecomment-1076451070= // This command requires the async package (https://www.npmjs.com/package/async) Cypress.Commands.add('waitForDom', () => { - cy.window().then(win => { + cy.window().then({ + // Don't timeout before waitForDom finishes + timeout: 10000 + }, win => { let timeElapsed = 0; cy.log("Waiting for DOM mutations to complete");