Skip to content

Commit

Permalink
fix(test): wait for files to load before opening file actions
Browse files Browse the repository at this point in the history
Signed-off-by: Elizabeth Danzberger <[email protected]>
  • Loading branch information
elzody committed May 8, 2024
1 parent eaa3443 commit db6fd6f
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions cypress/e2e/open.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,17 @@ describe('Open PDF with richdocuments', () => {
// opens the file using richdocuments
it('Open PDF with richdocuments', () => {
cy.get('[data-cy-files-list-row-name="document.pdf"]').as('pdf')
cy.get('@pdf').find('.action-items').as('actions')

cy.get('@actions').find('.action-item__menutoggle').click()
cy.get('.action-button__longtext').contains('Edit with Nextcloud Office').click()
cy.get('@pdf')
.find('.action-items')
.as('actions')

cy.wait(100)
cy.get('@actions')
.find('.action-item__menutoggle')
.click()
cy.get('.action-button__longtext')
.contains('Edit with Nextcloud Office')
.click()

// Wait for Collabora to open
cy.waitForViewer()
Expand Down

0 comments on commit db6fd6f

Please sign in to comment.