From 42ea591c52dba36edfd25321fe385bdd4014018d Mon Sep 17 00:00:00 2001 From: Jonas Date: Thu, 28 May 2026 11:04:31 +0200 Subject: [PATCH 1/2] test(playwright): add summary job so we can add it to merge rules Signed-off-by: Jonas --- .github/workflows/playwright.yml | 48 +++++++++++++++++++------------- 1 file changed, 29 insertions(+), 19 deletions(-) diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index 2b3054e2513..c1c02fcdc5e 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -11,18 +11,22 @@ permissions: contents: read jobs: - test: + playwright: timeout-minutes: 60 runs-on: ubuntu-latest + strategy: + matrix: + shardIndex: [1, 2, 3] + shardTotal: [3] steps: - name: Checkout app - uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0 + uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 with: persist-credentials: false - name: Check composer.json id: check_composer - uses: andstor/file-existence-action@076e0072799f4942c8bc574a82233e1e4d13e9d6 # v3.0.0 + uses: andstor/file-existence-action@558493d6c74bf472d87c84eab196434afc2fa029 # v3.1.0 with: files: 'composer.json' @@ -30,38 +34,44 @@ jobs: if: steps.check_composer.outputs.files_exists == 'true' run: composer install --no-dev - - name: Read package.json node and npm engines version - uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3 + - name: Read package.json + uses: nextcloud-libraries/parse-package-engines-action@122ae05d4257008180a514e1ddeb0c1b9d094bdd # v0.1.0 id: versions - with: - fallbackNode: '^20' - fallbackNpm: '^10' - - name: Set up node ${{ steps.versions.outputs.nodeVersion }} - uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0 + - name: Set up node + uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 with: - node-version: ${{ steps.versions.outputs.nodeVersion }} + node-version: ${{ steps.versions.outputs.node-version }} - - name: Set up npm ${{ steps.versions.outputs.npmVersion }} - run: npm i -g 'npm@${{ steps.versions.outputs.npmVersion }}' + - name: Set up npm + run: npm i -g 'npm@${{ steps.versions.outputs.steps.versions.outputs.package-manager-version }}' - name: Install node dependencies & build app env: CYPRESS_INSTALL_BINARY: 0 run: | npm ci - TESTING=true npm run build --if-present + npm run build --if-present - name: Install Playwright Browsers run: npx playwright install chromium --only-shell - name: Run Playwright tests - run: npx playwright test + run: npx playwright test --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }} - name: Upload results - uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 - if: always() + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 + if: ${{ !cancelled() }} with: - name: playwright-report + name: playwright-report_shard${{ matrix.shardIndex }} path: test-results/ - retention-days: 30 + retention-days: 7 + + summary: + runs-on: ubuntu-latest-low + needs: playwright + if: always() + name: playwright-summary + steps: + - name: Summary status + run: if ${{ needs.playwright.result != 'success' && needs.playwright.result != 'skipped' }}; then exit 1; fi From d54e717b4bc17f1439818b83cc2d7d32dfd4c25e Mon Sep 17 00:00:00 2001 From: Jonas Date: Sat, 30 May 2026 11:37:43 +0200 Subject: [PATCH 2/2] chore(deps): update playwright to 1.60.0 Signed-off-by: Jonas --- package-lock.json | 24 ++++++++++++------------ package.json | 2 +- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/package-lock.json b/package-lock.json index 21149ba4de4..0f0fead116e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -92,7 +92,7 @@ "@nextcloud/eslint-config": "^8.4.2", "@nextcloud/prettier-config": "^1.2.0", "@nextcloud/vite-config": "^1.7.2", - "@playwright/test": "^1.57.0", + "@playwright/test": "^1.60.0", "@types/markdown-it": "^14.1.2", "@vitejs/plugin-vue2": "^2.3.4", "@vitest/coverage-v8": "^4.0.18", @@ -4494,13 +4494,13 @@ } }, "node_modules/@playwright/test": { - "version": "1.57.0", - "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.57.0.tgz", - "integrity": "sha512-6TyEnHgd6SArQO8UO2OMTxshln3QMWBtPGrOCgs3wVEmQmwyuNtB10IZMfmYDE0riwNR1cu4q+pPcxMVtaG3TA==", + "version": "1.60.0", + "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.60.0.tgz", + "integrity": "sha512-O71yZIbAh/PxDMNGns37GHBIfrVkEVyn+AXyIa5dOTfb4/xNvRWV+Vv/NMbNCtODB/pO7vLlF2OTmMVLhmr7Ag==", "dev": true, "license": "Apache-2.0", "dependencies": { - "playwright": "1.57.0" + "playwright": "1.60.0" }, "bin": { "playwright": "cli.js" @@ -16654,13 +16654,13 @@ } }, "node_modules/playwright": { - "version": "1.57.0", - "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.57.0.tgz", - "integrity": "sha512-ilYQj1s8sr2ppEJ2YVadYBN0Mb3mdo9J0wQ+UuDhzYqURwSoW4n1Xs5vs7ORwgDGmyEh33tRMeS8KhdkMoLXQw==", + "version": "1.60.0", + "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.60.0.tgz", + "integrity": "sha512-hheHdokM8cdqCb0lcE3s+zT4t4W+vvjpGxsZlDnikarzx8tSzMebh3UiFtgqwFwnTnjYQcsyMF8ei2mCO/tpeA==", "dev": true, "license": "Apache-2.0", "dependencies": { - "playwright-core": "1.57.0" + "playwright-core": "1.60.0" }, "bin": { "playwright": "cli.js" @@ -16673,9 +16673,9 @@ } }, "node_modules/playwright-core": { - "version": "1.57.0", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.57.0.tgz", - "integrity": "sha512-agTcKlMw/mjBWOnD6kFZttAAGHgi/Nw0CZ2o6JqWSbMlI219lAFLZZCyqByTsvVAJq5XA5H8cA6PrvBRpBWEuQ==", + "version": "1.60.0", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.60.0.tgz", + "integrity": "sha512-9bW6zvX/m0lEbgTKJ6YppOKx8H3VOPBMOCFh2irXFOT4BbHgrx5hPjwJYLT40Lu+4qtD36qKc/Hn56StUW57IA==", "dev": true, "license": "Apache-2.0", "bin": { diff --git a/package.json b/package.json index ccc3a963e25..c37fa38a3bc 100644 --- a/package.json +++ b/package.json @@ -112,7 +112,7 @@ "@nextcloud/eslint-config": "^8.4.2", "@nextcloud/prettier-config": "^1.2.0", "@nextcloud/vite-config": "^1.7.2", - "@playwright/test": "^1.57.0", + "@playwright/test": "^1.60.0", "@types/markdown-it": "^14.1.2", "@vitejs/plugin-vue2": "^2.3.4", "@vitest/coverage-v8": "^4.0.18",