Skip to content

ci(frontend): publish SPA coverage by module on PRs - #216

Merged
mariusmm merged 1 commit into
mainfrom
feature/frontend-coverage-ci
Aug 3, 2026
Merged

ci(frontend): publish SPA coverage by module on PRs#216
mariusmm merged 1 commit into
mainfrom
feature/frontend-coverage-ci

Conversation

@mariusmm

@mariusmm mariusmm commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Run Vitest coverage (npm run test:coverage) in the frontend-tests CI job
  • Roll up line/branch/function rates by frontend/src module via scripts/frontend-coverage-summary.mjs
  • Publish the markdown summary to the GitHub Actions job summary and as a dedicated PR comment (message-id: frontend-coverage)
  • Upload HTML/LCOV/Cobertura artifacts; keep legacy marreq-core/tests/js tests as a separate step

Coverage snapshot (local, current suite)

5.7% lines (768 / 13,489) across the SPA — existing 74 tests.

Module Line rate
lib 82.5%
utils 79.2%
context 39.7%
hooks 18.1%
components/graph 16.3%
components 5.8%
pages 5.2%
api 2.9%
pages/catalog / pages/groups 0%

No coverage gate was added for frontend (would fail at ~6%). Backend gate remains 70%.

Test plan

  • CI frontend-tests is green
  • PR shows a Frontend SPA coverage comment with module table
  • Job summary includes the same table
  • Artifact frontend-coverage-html is uploaded
  • Legacy JS tests still run

Made with Cursor

Run Vitest coverage in the frontend-tests job, roll up line/branch/function
rates by src module, and post the summary to the job and PR comments alongside
backend coverage.
@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown

Frontend Code Coverage

Frontend SPA coverage (by module)

Module Line Rate Branch Rate Function Rate Health
api 2.9% (26 / 903) 100.0% 1.1%
components 5.8% (154 / 2668) 80.4% 36.8%
components/graph 16.3% (17 / 104) 100.0% 0.0%
components/reports 0.0% (0 / 20) 100.0% 100.0%
components/table 0.0% (0 / 48) 50.0% 50.0%
context 39.7% (48 / 121) 55.0% 50.0%
hooks 18.1% (36 / 199) 81.8% 44.4%
lib 82.5% (47 / 57) 100.0% 50.0%
pages 5.2% (356 / 6792) 75.3% 44.1%
pages/catalog 0.0% (0 / 1473) 12.5% 12.5%
pages/groups 0.0% (0 / 870) 0.0% 0.0%
src (root) 0.0% (0 / 128) 50.0% 50.0%
types 100.0% (0 / 0) 100.0% 100.0%
utils 79.2% (84 / 106) 97.8% 100.0%
Summary 5.7% (768 / 13489) 77.5% 23.2%

Generated from Vitest @vitest/coverage-v8 (frontend/src).

@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown

Code Coverage

Package Line Rate Complexity Health
marreq-core.src.routes 48% 0
marreq-server.src 62% 0
marreq-core.src.auth.guards 46% 0
marreq-core.src.fairings 89% 0
marreq-core.src.diff 100% 0
marreq-core.src.importers 5% 0
marreq-core.src.auth 91% 0
marreq-cloud.src 72% 0
marreq-core.src 67% 0
marreq-core.src.services 90% 0
marreq-core.src.services.semantic_search 75% 0
marreq-core.src.helper_functions 93% 0
marreq-core.src.deployment 83% 0
marreq-core.src.generators 0% 0
marreq-core.src.api 77% 0
marreq-core.src.models 81% 0
marreq-cloud.src.api 78% 0
marreq-cloud.src.fairings 100% 0
marreq-core.src.repository.cache 100% 0
marreq-core.src.repository 43% 0
marreq-core.src.reqif 83% 0
marreq-core.src.validation 96% 0
marreq-cloud.src.services 91% 0
marreq-core.src.auth.rate_limiter 94% 0
Summary 75% (22695 / 30307) 0

@mariusmm
mariusmm merged commit f8159fc into main Aug 3, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant