feat: add code coverage reporting via Codecov for backend and contracts#398
feat: add code coverage reporting via Codecov for backend and contracts#398binayyub4211 wants to merge 5 commits into
Conversation
|
hey, main was failing CI from broken auth imports + frontend parse errors. fixed and pushed to main now. please rebase to pick up the fixes: git fetch upstream
git rebase upstream/main
git push --force-with-leaseif there's a conflict, resolve it locally and we'll review once CI is green. |
|
hey, main CI is fully green now. there were several real TypeScript and test issues from #444's merge that have all been fixed. please rebase one more time: git fetch upstream
git rebase upstream/main
git push --force-with-leaseyour PR's diff should be much cleaner after this rebase since main now has the canonical versions of cancel.ts, sorobanService.ts, and the withdraw test. |
4d0bc9b to
9a1067f
Compare
done |
|
heads up: main's ci was broken (the Backend CI and Backend Docker Image CI jobs) until the fixes in #969 and #974 just landed, so the red backend/docker checks on this pr are almost certainly stale, they ran against the broken main. please rebase to re-test against the now-green main: |
ogazboiz
left a comment
There was a problem hiding this comment.
the codecov + coverage setup is a reasonable idea, but two real blockers:
- backend/package-lock.json has unresolved merge-conflict markers (<<<<<<< HEAD around line 55), which breaks npm ci everywhere. resolve the conflict and regenerate the lockfile.
- the @vitest/coverage-v8 pin is incompatible with the installed vitest ("does not provide export BaseCoverageProvider"), align coverage-v8 to your vitest major.
heads up this pr is actually the source of the coverage-v8 npm ci churn that's reding several other prs too, so getting it right helps everyone. also #927 also adds codecov + mangles the lockfile, you two overlap, pick one and close the other.
Closes #373
Implemented comprehensive code coverage tracking for both backend (Vitest) and smart contracts (Tarpaulin). Coverage reports are now automatically uploaded to Codecov during CI runs, with enforced thresholds to prevent coverage erosion.
Changes:
Backend: Enabled lcov reporting, set 60% thresholds, and added @vitest/coverage-v8.
Contracts: Integrated cargo-tarpaulin with 70% failure threshold.
CI: Added Codecov upload actions for all coverage reports.
UI/Docs: Added Codecov badge to README and created codecov.yml for PR comments.
Verification:
Verified Vitest configuration structure.
Validated GitHub Actions YAML syntax.
Ensured thresholds match the requirements.