ci: enhanced CI/CD and test coverage

- Update version from 0.2.0 to 0.9.0
- Upgrade Vitest from v3 to v4 for improved testing capabilities
- Add @vitest/coverage-v8 for comprehensive code coverage reporting
- Enhance GitHub Actions CI workflow with separate unit and integration
test runs
- Integrate Codecov v5 for coverage reporting and test results tracking
- Add JUnit reporter for better test result analysis
- Configure @codecov/vite-plugin for automated coverage collection
This commit is contained in:
2025-10-23 00:59:18 -05:00
parent c7852ddab4
commit 852277d648
5 changed files with 498 additions and 168 deletions

View File

@@ -71,20 +71,30 @@ jobs:
run: pnpm install --frozen-lockfile
- name: Run unit tests
run: pnpm test:run
run: pnpm test:run:coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Run integration tests
run: pnpm test:integration
run: pnpm test:integration:coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage
uses: codecov/codecov-action@v4
- name: Run tests with junit reporter
run: pnpm vitest run --reporter=junit --outputFile=test-report.junit.xml
if: always()
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
if: always()
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage/coverage-final.json
flags: unittests
name: codecov-umbrella
fail_ci_if_error: false
- name: Upload test results to Codecov
if: ${{ !cancelled() }}
uses: codecov/test-results-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
# Build verification
build: