Skip to content

adds coverage and failunder to pytest command#68

Merged
samgdotson merged 2 commits into
arfc:mainfrom
fredshone:coverage
Sep 23, 2024
Merged

adds coverage and failunder to pytest command#68
samgdotson merged 2 commits into
arfc:mainfrom
fredshone:coverage

Conversation

@fredshone

Copy link
Copy Markdown
Contributor

Nice coverage - would be a shame if you ever let it slip...

Adds pytest-cov dependancy to default dependancies and "straps" to pytest command. So that running pytest also checks coverage.

I have added a fail for if coverage dips below 80%. This is easy to change.

@samgdotson samgdotson left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fredshone thanks for the pull request! Really above and beyond work. Embarrassingly, I forgot to actually add the coverage test in CI, despite my claims in #65. Regardless, your implementation in pyproject.toml is better than my approach, which was just to have it in the CI.yml.

More embarrassingly, despite appearances osier does not have 99% code coverage (one can dream)! The suggestions I made simply adjust the commands to

  1. check only the osier source files
  2. reduce the passing requirement such that this PR will pass the checks.

Once the changes are adopted, I'm happy to merge (I could accept the changes myself but I feel that decorum dictates I let you do that 😄). Let me know either way -- and thanks again for the PR!

Comment thread pyproject.toml Outdated
Comment thread pyproject.toml Outdated
@samgdotson samgdotson added Comp:Build This issue has to do with the build system of the code/doc (makefiles, cmake, install errors) Difficulty:1-Beginner This issue does not require expert knowledge and may be a good issue for new contributors. Priority:2-Normal This work is important and should be completed ASAP. Status:5-In Review This issue has been handled, and the solution is being reviewed. (probably as a PR) Type:Test Is related to software testing. Failing tests, necessary new tests, test frameworks, etc. labels Sep 18, 2024
@samgdotson samgdotson added this to the JOSS publication -- Osier milestone Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Comp:Build This issue has to do with the build system of the code/doc (makefiles, cmake, install errors) Difficulty:1-Beginner This issue does not require expert knowledge and may be a good issue for new contributors. Priority:2-Normal This work is important and should be completed ASAP. Status:5-In Review This issue has been handled, and the solution is being reviewed. (probably as a PR) Type:Test Is related to software testing. Failing tests, necessary new tests, test frameworks, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants