Skip to content

Report test-code coverage in CI - #709

Open
anshurajbisoyi98-ctrl wants to merge 1 commit into
optimagic-dev:mainfrom
anshurajbisoyi98-ctrl:ci-564-test-code-coverage
Open

anshurajbisoyi98-ctrl wants to merge 1 commit into
optimagic-dev:mainfrom
anshurajbisoyi98-ctrl:ci-564-test-code-coverage

Conversation

@anshurajbisoyi98-ctrl

@anshurajbisoyi98-ctrl anshurajbisoyi98-ctrl commented Oct 4, 2026 •

Copy link
Copy Markdown

What problem do you want to solve?

Related to #564 and the coverage-reporting step requested in #571.

The CI coverage task currently measures only src, and Codecov explicitly ignores tests. This change adds --cov=tests alongside --cov=src and removes the test-directory exclusion from Codecov, making uncovered test helpers visible for review.

This is the reporting step only. It does not remove test helpers, add coverage exclusions, enforce 100% test coverage, or resolve all of #564. Categorizing uncovered test code can follow once the full CI report is available.

Validation on macOS with Python 3.13:

  • 28 focused tests passed (tests/optimagic/test_decorators.py and tests/optimagic/test_batch_evaluators.py).
  • Confirmed that the generated XML report contains source and test files.
  • All applicable pre-commit hooks passed for the two changed files.
  • git diff --check passed.

The full test suite and remote CI have not yet been verified.

Todo

  • Target the right branch and pick an appropriate title.
  • Close the relevant issue automatically: not applicable because this PR addresses only the reporting step of Ensure 100% coverage in tests #564.
  • Verify the full CI run and uploaded Codecov report after submission.

AI assistance

Codex assisted with implementation and local verification, .

Signed-off-by: Anshu Raj Bisoyi <anshurajbisoyi98@gmail.com>

This branch has not been deployed

No deployments
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.

1 participant