diff options
author | Louis Chemineau <louis@chmn.me> | 2024-03-12 18:49:20 +0100 |
---|---|---|
committer | Louis Chemineau <louis@chmn.me> | 2024-03-14 11:07:20 +0100 |
commit | 01fe326df16bd479a0c75842b6baa22eebb9e279 (patch) | |
tree | 7baf22104fad86ea820d2bc08fed87c36f943fdb /cypress/e2e/files_sharing | |
parent | 2de9880d79adeeab0e0a01ce3992de404a0c274d (diff) | |
download | nextcloud-server-01fe326df16bd479a0c75842b6baa22eebb9e279.tar.gz nextcloud-server-01fe326df16bd479a0c75842b6baa22eebb9e279.zip |
test(files): Add e2e tests for live photo sync
Signed-off-by: Louis Chemineau <louis@chmn.me>
Diffstat (limited to 'cypress/e2e/files_sharing')
-rw-r--r-- | cypress/e2e/files_sharing/filesSharingUtils.ts | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cypress/e2e/files_sharing/filesSharingUtils.ts b/cypress/e2e/files_sharing/filesSharingUtils.ts index ee80041b619..cb407153380 100644 --- a/cypress/e2e/files_sharing/filesSharingUtils.ts +++ b/cypress/e2e/files_sharing/filesSharingUtils.ts @@ -58,8 +58,10 @@ export function updateShare(fileName: string, index: number, shareSettings: Part if (shareSettings.download !== undefined) { cy.get('[data-cy-files-sharing-share-permissions-checkbox="download"]').find('input').as('downloadCheckbox') if (shareSettings.download) { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@downloadCheckbox').check({ force: true, scrollBehavior: 'nearest' }) } else { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@downloadCheckbox').uncheck({ force: true, scrollBehavior: 'nearest' }) } } @@ -67,8 +69,10 @@ export function updateShare(fileName: string, index: number, shareSettings: Part if (shareSettings.read !== undefined) { cy.get('[data-cy-files-sharing-share-permissions-checkbox="read"]').find('input').as('readCheckbox') if (shareSettings.read) { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@readCheckbox').check({ force: true, scrollBehavior: 'nearest' }) } else { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@readCheckbox').uncheck({ force: true, scrollBehavior: 'nearest' }) } } @@ -76,8 +80,10 @@ export function updateShare(fileName: string, index: number, shareSettings: Part if (shareSettings.update !== undefined) { cy.get('[data-cy-files-sharing-share-permissions-checkbox="update"]').find('input').as('updateCheckbox') if (shareSettings.update) { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@updateCheckbox').check({ force: true, scrollBehavior: 'nearest' }) } else { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@updateCheckbox').uncheck({ force: true, scrollBehavior: 'nearest' }) } } @@ -85,8 +91,10 @@ export function updateShare(fileName: string, index: number, shareSettings: Part if (shareSettings.delete !== undefined) { cy.get('[data-cy-files-sharing-share-permissions-checkbox="delete"]').find('input').as('deleteCheckbox') if (shareSettings.delete) { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@deleteCheckbox').check({ force: true, scrollBehavior: 'nearest' }) } else { + // Force:true because the checkbox is hidden by the pretty UI. cy.get('@deleteCheckbox').uncheck({ force: true, scrollBehavior: 'nearest' }) } } |