Repository navigation
ci(coverage): add vitest coverage reporting with enforced minimum threshold - #26
Open
comandanto wants to merge 1 commit into
Open
comandanto wants to merge 1 commit into
comandanto wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
Closes #17.
@vitest/coverage-v8(v5.0.5) todevDependenciesto matchvitest.test.coverageinvitest.config.tstargetingsrc/**/*.ts(excludingsrc/main.tsentrypoint and declaration files) with minimum thresholds:"test:coverage": "vitest run --coverage"script inpackage.json.npm run test:coverageinto.github/workflows/ci.yml.Why this belongs in this repository
Ensures that pull requests cannot silently regress coverage on critical execution paths (e.g. policy rules, transaction verification, session authentication), failing CI automatically if measured coverage drops below the enforced thresholds.
Other repo API/ABI impact
None. No runtime dependency or API surface changes.
Tests and evidence
npm run test:coveragelocally: generated complete coverage report and passed all thresholds (113 tests passing).npm run checkandnpm run build: both exit 0 cleanly.lines: 99:vitestcorrectly reported threshold failure and exited with code 1 before reverting to 95.Security/privacy and Stellar impact
None. No secrets, credentials, or Soroban smart contract interactions affected.