Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[INF] Merge codecov.yml into tests.yml #1185

Merged
merged 2 commits into from
Nov 2, 2022

Conversation

Zeroto521
Copy link
Member

@Zeroto521 Zeroto521 commented Oct 31, 2022

PR Description

Please describe the changes proposed in the pull request:

Fix code coverage difference in the dev branch, PR, and envs.
Get the same coverage result from the dev branch and PR.

The way of launching pytest is thiny different. And that causes the code coverage sometimes passed sometimes failed.
image

pytest -m "${{ matrix.test-subset }}"

PR Checklist

Please ensure that you have done the following:

  1. PR in from a fork off your branch. Do not PR from <your_username>:dev, but rather from <your_username>:<feature-branch_name>.
  1. If you're not on the contributors list, add yourself to AUTHORS.md.
  1. Add a line to CHANGELOG.md under the latest version header (i.e. the one that is "on deck") describing the contribution.
    • Do use some discretion here; if there are multiple PRs that are related, keep them in a single line.

Automatic checks

There will be automatic checks run on the PR. These include:

  • Building a preview of the docs on Netlify
  • Automatically linting the code
  • Making sure the code is documented
  • Making sure that all tests are passed
  • Making sure that code coverage doesn't go down.

Relevant Reviewers

Please tag maintainers to review.

@Zeroto521
Copy link
Member Author

Another reason code coverage failed is that pytest doesn't add --cov-append option.
--cov-append can get a sum coverage. I'll add this option in the next PR.
First let us merge codecov.yml into tests.yml. Keep the same test logic for the dev branch or a PR.

@codecov
Copy link

codecov bot commented Oct 31, 2022

Codecov Report

Merging #1185 (0e9804a) into dev (8445dc0) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##              dev    #1185   +/-   ##
=======================================
  Coverage   97.70%   97.70%           
=======================================
  Files          76       76           
  Lines        3482     3482           
=======================================
  Hits         3402     3402           
  Misses         80       80           

@Zeroto521 Zeroto521 merged commit 9c02ab8 into pyjanitor-devs:dev Nov 2, 2022
@Zeroto521 Zeroto521 deleted the ci/merge-codecov branch November 2, 2022 00:44
@Zeroto521 Zeroto521 mentioned this pull request Nov 2, 2022
3 tasks
@Zeroto521
Copy link
Member Author

image

That failed due to we pushed coverage separately.
So that's the latest coverage.

Add --cov-append for pytest can get a sum coverage.

@ericmjl
Copy link
Member

ericmjl commented Nov 2, 2022

Ah, that is now making sense! Thank you for figuring this out, @Zeroto521!

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.

2 participants