mirror of
https://github.com/Xevion/rdap.git
synced 2025-12-06 03:16:07 -06:00
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:
26
.github/workflows/ci.yml
vendored
26
.github/workflows/ci.yml
vendored
@@ -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:
|
||||
|
||||
Reference in New Issue
Block a user