From 3e014b90ae4ec6ce123f311161dbcd216c9a9efe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20M=C3=B6rling?= Date: Tue, 19 May 2026 20:12:35 +0200 Subject: [PATCH] ci: remove redundant test steps and add coverage artifact uploads The lint-and-test job was running tests twice: - 'Backend unit tests' ran tests without coverage - 'Backend coverage' ran the same tests again with JaCoCo - 'Frontend unit tests' ran tests without coverage - 'Frontend coverage' ran the same tests again with v8 coverage This wasted ~2x test time for no benefit since coverage steps already run all tests. - Remove 'Backend unit tests' and 'Frontend unit tests' steps - Keep only coverage steps (jacocoTestCoverageVerification and test:coverage) - Add artifact upload steps for both coverage HTML reports: - backend-coverage: backend/build/reports/jacoco/test/html/ - frontend-coverage: frontend/coverage/ - 7-day retention to avoid storage bloat Result: lint-and-test job runs faster (no duplicate test runs) and produces downloadable HTML coverage reports visible in the Forgejo Actions UI. --- .forgejo/workflows/ci.yml | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml index 561eec8..fdf4110 100644 --- a/.forgejo/workflows/ci.yml +++ b/.forgejo/workflows/ci.yml @@ -39,13 +39,6 @@ jobs: run: npx vue-tsc --noEmit working-directory: frontend - - name: Frontend unit tests - run: npm run test - working-directory: frontend - - - name: Backend unit tests - run: ./gradlew :backend:test - - name: Backend coverage run: ./gradlew :backend:jacocoTestCoverageVerification @@ -53,6 +46,20 @@ jobs: run: npm run test:coverage working-directory: frontend + - name: Upload backend coverage report + uses: actions/upload-artifact@v4 + with: + name: backend-coverage + path: backend/build/reports/jacoco/test/html/ + retention-days: 7 + + - name: Upload frontend coverage report + uses: actions/upload-artifact@v4 + with: + name: frontend-coverage + path: frontend/coverage/ + retention-days: 7 + e2e: name: E2E browser tests runs-on: ubuntu-latest