-
Notifications
You must be signed in to change notification settings - Fork 130
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
get_dupes() grouped data error fix #345
Conversation
Codecov Report
@@ Coverage Diff @@
## master #345 +/- ##
=====================================
Coverage 100% 100%
=====================================
Files 26 26
Lines 996 1002 +6
=====================================
+ Hits 996 1002 +6
|
I'm not clear on exactly what codecov is if anyone can provide some feedback on what I've done wrong! |
codecov checks which lines of code are run when all the tests are run. Your PR has two "misses", that is there are two lines that are not run in any test: https://codecov.io/gh/sfirke/janitor/pull/345/diff?src=pr&el=tree#diff-Ui9nZXRfZHVwZXMuUg Looks like it's the grouped_df warning, that could be checked with a new test that looks at |
Code itself looks great though! 👍 After reviewing it, now I wonder if it's impossible to test that chunk that codecov says is missing coverage, because the message only prints if I don't see a way to fake an interactive environment to run that warning. The only idea I have is to just not have tests for those two lines and acknowledge that by ending those two lines with |
Looks like you were correct about the interactive issue. I'll add #nocov to those lines. |
…ta because codecov can't fake an interactive session.
Looks like it didn't run, I'm guessing because |
…ecov bot can't fake an interactive session.
Excellent! Thanks @jzadra |
Description
If data is grouped:
Added tests that check that
Related Issue
Addresses #329.
Example
x <- mtcars %>% group_by(cyl, gear)
get_dupes(x)