docs: add code coverage section to test README#5717
Open
docs: add code coverage section to test README#5717
Conversation
d34645d to
9cab944
Compare
Document how contributors can measure code coverage locally with pytest-cov, link to the project's Codecov dashboard, and note the ~80% coverage goal. Mentions the pyproject.toml configuration and the LONG_TESTS / EXTERNAL_SYSTEM gating that affects local figures versus what CI measures. fixes ossf#4952 Signed-off-by: ABD <abdullahfazili3614@gmail.com>
Signed-off-by: ABD <abdullahfazili3614@gmail.com>
21ae711 to
29a6a21
Compare
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.
Summary
Adds a Measuring code coverage section to
doc/test/README.md, addressing #4952.The section covers:
pytest-covis the tool used and is included in the[dev]extraspytest --cov) and produce an HTML reportpyproject.toml([tool.coverage.run]/[tool.coverage.report])The new section is inserted between Running tests on different versions of Python and Adding new tests: CVE mapping tests, and the table of contents is updated to match.
Test plan
pre-commit run --files doc/test/README.md— codespell passes; all Python-only hooks correctly skip the markdown filegitlint --msg-filenameon the commit message — passes (Conventional Commitsdocs:type)fixes #4952