Skip to content

ci(coverage): add frontend and contract coverage thresholds#449

Merged
PrincessnJoy merged 2 commits into
PrincessnJoy:mainfrom
unixfundz:feat/314-coverage-thresholds
Jun 26, 2026
Merged

ci(coverage): add frontend and contract coverage thresholds#449
PrincessnJoy merged 2 commits into
PrincessnJoy:mainfrom
unixfundz:feat/314-coverage-thresholds

Conversation

@unixfundz

Copy link
Copy Markdown
Contributor

Closes #314

Changes

.github/workflows/ci.yml

  • Renamed coverage job to Contract Coverage; added --fail-under 60 to cargo tarpaulin — CI fails if contract line coverage drops below 60%
  • Added frontend-coverage job:
    • Runs after the frontend job
    • Runs npm run coverage (Vitest) — Vitest exits non-zero if any threshold is not met, blocking the CI run

frontend/package.json

  • Added test and coverage scripts (Vitest)
  • Added vitest@1.6.0 and @vitest/coverage-v8@1.6.0 as pinned dev dependencies

frontend/vite.config.ts

  • Added test block configuring Vitest with jsdom environment and v8 coverage provider
  • Set 60% threshold on lines, functions, branches, and statements — Vitest fails CI if any metric falls below

Thresholds

Target Tool Threshold
Rust contracts cargo-tarpaulin 60% lines
Frontend Vitest + v8 60% lines / functions / branches / statements

@PrincessnJoy PrincessnJoy merged commit df8bceb into PrincessnJoy:main Jun 26, 2026
1 of 3 checks passed
@drips-wave

drips-wave Bot commented Jun 26, 2026

Copy link
Copy Markdown

@unixfundz Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

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.

Add frontend and contract coverage thresholds to CI

2 participants