Merge pull request #47671 from nextcloud/chore/cypress-intercept-timeout

test(cypress): Await promise in response to prevent timeout
This commit is contained in:
Ferdinand Thiessen 2024-09-02 17:42:17 +02:00 committed by GitHub
commit 69f4a397d1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -78,7 +78,10 @@ describe('files: Rename nodes', { testIsolation: true }, () => {
cy.intercept(
'MOVE',
/\/remote.php\/dav\/files\//,
async () => { await promise },
(request) => {
// we need to wait in the onResponse handler as the intercept handler times out otherwise
request.on('response', async () => { await promise })
},
).as('moveFile')
// Start the renaming