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

remove logically unreachable lines to get 100 percent coverage #116

Merged
merged 1 commit into from
Jul 25, 2023

Conversation

maxwest-uw
Copy link
Contributor

Change Description

while waiting on some other PRs, I decided to address something that's been bothering me... the hipscat unit tests are off from 100 percent coverage by two lines 😭 however, when I tried writing a test that would cover this, I realized that the lines in question are unreachable, as a child node cannot be created before a parent node, meaning that a user can never pass a list of children nodes into the init of a parent node. I went ahead and removed the code so that we can have full coverage :bowtie:

Solution Description

removed unreachable lines.

Code Quality

  • I have read the Contribution Guide
  • My code follows the code style of this project
  • My code builds (or compiles) cleanly without any errors or warnings
  • My code contains relevant comments and necessary documentation

@codecov
Copy link

codecov bot commented Jul 24, 2023

Codecov Report

Merging #116 (d532af9) into main (20261fd) will increase coverage by 0.14%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             main      #116      +/-   ##
===========================================
+ Coverage   99.85%   100.00%   +0.14%     
===========================================
  Files          45        45              
  Lines        1410      1407       -3     
===========================================
- Hits         1408      1407       -1     
+ Misses          2         0       -2     
Files Changed Coverage Δ
src/hipscat/pixel_tree/pixel_node.py 100.00% <ø> (+3.57%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Contributor

@smcguire-cmu smcguire-cmu left a comment

Choose a reason for hiding this comment

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

Thank you! I've been meaning to remove this, you're right that some changes were made to the logic which makes this unreachable.

@maxwest-uw maxwest-uw merged commit c533211 into main Jul 25, 2023
10 checks passed
@maxwest-uw maxwest-uw deleted the hundred_percent_coverage branch July 25, 2023 19:47
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