Conversation
There was a problem hiding this comment.
Pull request overview
Adds automated test coverage reporting to CI and publishes a coverage report (and badge) to GitHub Pages.
Changes:
- Add a coverage badge link to the README.
- Split CI tests into unit/integration jobs, generate/merge Cobertura coverage, enforce a minimum coverage threshold, and publish the report to GitHub Pages on
master. - Increase integration test timeout to 5 minutes to reduce CI flakiness.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| README.md | Adds a GitHub Pages coverage badge/link. |
| API.IntegrationTests/AssemblyAttributes.cs | Extends integration test timeout to 5 minutes. |
| .github/workflows/ci-build.yml | Adds coverage generation/enforcement and Pages publishing; restructures test jobs and job dependencies. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| build: | ||
| name: Build (${{ matrix.image }}) | ||
| runs-on: ubuntu-latest | ||
| needs: [coverage] |
There was a problem hiding this comment.
build now needs: [coverage], but the coverage job only runs for PRs / workflow_* / develop / master. For push events on other branches (the workflow is configured to run on push to **), coverage will be skipped and build will be skipped as well, which is likely unintended regression in CI feedback. Consider either (a) removing the build -> coverage dependency, or (b) expanding coverage (and its prerequisites) to run on the same event/branch set as build so builds still execute on branch pushes.
| needs: [coverage] |
| name: Coverage | ||
| runs-on: ubuntu-latest | ||
| needs: [unit-tests, integration-tests] | ||
| if: ${{ github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.ref_name == 'develop' || github.ref_name == 'master' }} |
There was a problem hiding this comment.
coverage declares needs: [unit-tests, integration-tests], but integration-tests is conditionally skipped via its job-level if. When that happens, coverage will also be skipped (and anything depending on it), even though unit test coverage artifacts may exist. If integration tests are optional for some events/branches, make the dependency optional by removing integration-tests from needs and handling “no integration report found” in the merge step, or ensure integration-tests always runs (e.g., keep the job but no-op the test step) on events where you still want coverage/build to proceed.
| if: ${{ github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.ref_name == 'develop' || github.ref_name == 'master' }} | |
| if: ${{ always() && needs.unit-tests.result == 'success' && (needs.integration-tests.result == 'success' || needs.integration-tests.result == 'skipped') && (github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.ref_name == 'develop' || github.ref_name == 'master') }} |
No description provided.