Skip to content

Commit

Permalink
Merge pull request #2416 from nextcloud/fix/cypress
Browse files Browse the repository at this point in the history
ci: Run cypress tests properly again on CI
  • Loading branch information
juliusknorr authored Aug 13, 2024
2 parents bd99947 + c233885 commit 8f152fb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
SPLIT: ${{ matrix.total-containers }}
SPLIT_INDEX: ${{ matrix.containers == 'component' && 0 || matrix.containers }}```
SPLIT_INDEX: ${{ matrix.containers == 'component' && 0 || matrix.containers }}

- name: Upload snapshots
uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4.3.4
Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/sharing/download-share.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ describe(`Download ${fileName} from viewer in link share`, function() {

it('See the full screen and download icons in the menu', function() {
cy.get('body > .v-popper__popper ul span.fullscreen-icon').should('be.visible')
cy.get(`body > .v-popper__popper ul a.action-link[href*='/s/${token}/download']`).should('be.visible')
cy.get(`body > .v-popper__popper ul a.action-link[href*='/public.php/dav/files/${token}/image1.jpg']`).should('be.visible')
})

it('Download the image', function() {
// https://github.com/cypress-io/cypress/issues/14857
cy.window().then((win) => { setTimeout(() => { win.location.reload() }, 5000) })
// download the file
cy.get(`body > .v-popper__popper a.action-link[href*='/s/${token}/download']`).click()
cy.get(`body > .v-popper__popper ul a.action-link[href*='/public.php/dav/files/${token}/image1.jpg']`).click()
})

it('Compare downloaded file with asset by size', function() {
Expand Down

0 comments on commit 8f152fb

Please sign in to comment.