diff options
author | Ferdinand Thiessen <opensource@fthiessen.de> | 2023-08-10 15:49:20 +0200 |
---|---|---|
committer | Ferdinand Thiessen <opensource@fthiessen.de> | 2023-08-26 20:56:09 +0200 |
commit | 5e9a6c1a0b7d32913429f0471b1be41e76fd20c1 (patch) | |
tree | 1231bf471dec1ce426a82c89e4de0d3f8880a9c1 /cypress | |
parent | 3d74ed85ff32d2e807c26e59c20352c3f94cf19e (diff) | |
download | nextcloud-server-5e9a6c1a0b7d32913429f0471b1be41e76fd20c1.tar.gz nextcloud-server-5e9a6c1a0b7d32913429f0471b1be41e76fd20c1.zip |
fix(cypress): Fix the user theming cypress test for the new filepicker
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'cypress')
-rw-r--r-- | cypress/e2e/theming/user-background.cy.ts | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/cypress/e2e/theming/user-background.cy.ts b/cypress/e2e/theming/user-background.cy.ts index 92617b33b59..367a237348a 100644 --- a/cypress/e2e/theming/user-background.cy.ts +++ b/cypress/e2e/theming/user-background.cy.ts @@ -210,10 +210,17 @@ describe('User select a custom background', function() { it('Select a custom background', function() { cy.intercept('*/apps/theming/background/custom').as('setBackground') + cy.on('uncaught:exception', (err) => { + // This can happen because of blink engine & skeleton animation, its not a bug just engine related. + if (err.message.includes('ResizeObserver loop limit exceeded')) { + return false + } + }) + // Pick background cy.get('[data-user-theming-background-custom]').click() - cy.get(`#picker-filestable tr[data-entryname="${image}"]`).click() - cy.get('#oc-dialog-filepicker-content ~ .oc-dialog-buttonrow button.primary').click() + cy.get('.file-picker__files tr').contains(image).click() + cy.get('.dialog__actions .button-vue--vue-primary').click() // Wait for background to be set cy.wait('@setBackground') @@ -242,10 +249,17 @@ describe('User changes settings and reload the page', function() { it('Select a custom background', function() { cy.intercept('*/apps/theming/background/custom').as('setBackground') + cy.on('uncaught:exception', (err) => { + // This can happen because of blink engine & skeleton animation, its not a bug just engine related. + if (err.message.includes('ResizeObserver loop limit exceeded')) { + return false + } + }) + // Pick background cy.get('[data-user-theming-background-custom]').click() - cy.get(`#picker-filestable tr[data-entryname="${image}"]`).click() - cy.get('#oc-dialog-filepicker-content ~ .oc-dialog-buttonrow button.primary').click() + cy.get('.file-picker__files tr').contains(image).click() + cy.get('.dialog__actions .button-vue--vue-primary').click() // Wait for background to be set cy.wait('@setBackground') |