feat(test): WP-46 — Vitest coverage (report-only)

Enable coverage via the @angular/build:unit-test builder's first-class options: a
`coverage` configuration on the test target (v8 provider, text-summary/html/lcov,
excludes for specs/stories/contracts/generated client) + `npm run test:coverage`.
Report-only (no thresholds) — visibility first. CI's test step now runs test:coverage
(strict superset: fails on a failing test, never on coverage). Baseline ~71% stmts.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
eho
2026-07-23 14:23:55 +02:00
co-authored by Claude Opus 4.8
parent 7d2a36ff22
commit f8cd77a48a
7 changed files with 157 additions and 8 deletions
+3 -1
View File
@@ -31,7 +31,9 @@ jobs:
- run: npm run dep:check
- run: npm run format:check
- run: npm run check:tokens
- run: npm test
# Runs the full suite AND reports coverage (WP-46, report-only — no thresholds, so
# it can't fail on coverage; it still fails on a failing test, like `npm test` did).
- run: npm run test:coverage
# --localize builds every configured locale (nl + en, angular.json's i18n
# block) in one pass; i18nMissingTranslation:"error" (angular.json) fails
# this step if messages.en.xlf is missing a unit the source (WP-20) gains.