Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ env:
# n.b. server will use head_ref, as we want to test the PR branch.
BRANCH: ${{ github.base_ref || github.ref_name }}


permissions:
contents: read

Expand Down Expand Up @@ -54,7 +53,7 @@ jobs:
id: check_composer
uses: andstor/file-existence-action@558493d6c74bf472d87c84eab196434afc2fa029 # v3.1.0
with:
files: 'composer.json'
files: "composer.json"

- name: Install composer dependencies
if: steps.check_composer.outputs.files_exists == 'true'
Expand All @@ -64,8 +63,8 @@ jobs:
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
id: versions
with:
fallbackNode: '^24'
fallbackNpm: '^11.3'
fallbackNode: "^24"
fallbackNpm: "^11.3"

- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
Expand All @@ -81,7 +80,7 @@ jobs:
TESTING=true npm run build --if-present

- name: Save context
uses: buildjet/cache/save@3e70d19e31d6a8030aeddf6ed8dbe601f94d09f4 # v4.0.2
uses: actions/cache/save@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
key: cypress-context-${{ github.run_id }}
path: ./
Expand All @@ -95,13 +94,13 @@ jobs:
matrix:
# Run multiple copies of the current job in parallel
# Please increase the number or runners as your tests suite grows
containers: ['1', '2']
containers: ["1", "2", "3"]

name: runner ${{ matrix.containers }}

steps:
- name: Restore context
uses: buildjet/cache/restore@3e70d19e31d6a8030aeddf6ed8dbe601f94d09f4 # v4.0.2
uses: actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
fail-on-cache-miss: true
key: cypress-context-${{ github.run_id }}
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/cypress.yml.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/.github/workflows/cypress.yml b/.github/workflows/cypress.yml
index f5ca9aad..23dd9739 100644
--- a/.github/workflows/cypress.yml
+++ b/.github/workflows/cypress.yml
@@ -95,7 +95,7 @@ jobs:
matrix:
# Run multiple copies of the current job in parallel
# Please increase the number or runners as your tests suite grows
- containers: ['component', '1', '2', '3']
+ containers: ['1', '2', '3']

name: runner ${{ matrix.containers }}

4 changes: 1 addition & 3 deletions cypress.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { configureNextcloud, runOcc, startNextcloud, stopNextcloud, waitOnNextcloud } from '@nextcloud/cypress/docker'
// eslint-disable-next-line n/no-extraneous-import
import { configureNextcloud, runOcc, startNextcloud, stopNextcloud, waitOnNextcloud } from '@nextcloud/e2e-test-server'
import { defineConfig } from 'cypress'

import vitePreprocessor from 'cypress-vite'

export default defineConfig({
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/screenshots.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

import { User } from '@nextcloud/cypress'
import { User } from '@nextcloud/e2e-test-server'
import { createFolder, getFileListRow, renameFile } from './filesUtils.ts'
import { addTag, showActivityTab } from './sidebarUtils.ts'

Expand Down
10 changes: 5 additions & 5 deletions cypress/e2e/settings.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

import type { User } from "@nextcloud/cypress"
import type { User } from "@nextcloud/e2e-test-server"

describe('Check that user\'s settings survive a reload', () => {
let user: User
Expand All @@ -21,14 +21,14 @@ describe('Check that user\'s settings survive a reload', () => {
it('Form survive a reload', () => {
cy.intercept({ method: 'POST', url: '**/activity/settings' }).as('apiCall')

cy.get("#app-content input[type='checkbox']").uncheck({ force: true })
cy.get("#app-content input[type='checkbox']").should('not.be.checked')
cy.get("#activity-user-settings input[type='checkbox']").uncheck({ force: true })
cy.get("#activity-user-settings input[type='checkbox']").should('not.be.checked')
cy.wait('@apiCall')

cy.reload()

cy.get("#app-content input[type='checkbox']").uncheck({ force: true })
cy.get("#app-content input[type='checkbox']").should('not.be.checked')
cy.get("#activity-user-settings input[type='checkbox']").uncheck({ force: true })
cy.get("#activity-user-settings input[type='checkbox']").should('not.be.checked')

cy.get('#file_changed_notification').check({ force: true })
cy.get('#comments_email').check({ force: true })
Expand Down
4 changes: 1 addition & 3 deletions cypress/support/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
/* eslint-disable n/no-unpublished-import */
import { addCommands } from '@nextcloud/cypress'
import { addCommands } from '@nextcloud/e2e-test-server/cypress'

import 'cypress-wait-until'

import '@testing-library/cypress/add-commands'

// Add custom commands
Expand Down
19 changes: 0 additions & 19 deletions cypress/support/component-index.html

This file was deleted.

44 changes: 0 additions & 44 deletions cypress/support/component.ts

This file was deleted.

Loading
Loading