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

Add inspection testing covering any construct lacking data #176

Conversation

sadielbartholomew
Copy link
Member

@sadielbartholomew sadielbartholomew commented Mar 2, 2022

Follow-on PR to #175 to add some extra testing covering all other constructs that weren't buggy but it would regardless be good to check in a similar way, namely to call str() and repr() on when the constructs have no data, for any which can take data, so excluding only cell methods and coordinate references from the data model. Context can be found in #175 (review).

@davidhassell shall I also add equivalent tests to cf-python, or is that overkill?

@sadielbartholomew sadielbartholomew added the testing Issues related to units tests and their coverage label Mar 2, 2022
@sadielbartholomew sadielbartholomew self-assigned this Mar 2, 2022
@codecov
Copy link

codecov bot commented Mar 2, 2022

Codecov Report

Merging #176 (d7fc3b9) into master (76d2102) will increase coverage by 0.03%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #176      +/-   ##
==========================================
+ Coverage   88.71%   88.74%   +0.03%     
==========================================
  Files         101      101              
  Lines       10806    10806              
==========================================
+ Hits         9586     9589       +3     
+ Misses       1220     1217       -3     
Flag Coverage Δ
unittests 88.74% <ø> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
cfdm/read_write/netcdf/netcdfread.py 83.50% <0.00%> (+0.06%) ⬆️
cfdm/field.py 87.06% <0.00%> (+0.20%) ⬆️
cfdm/domain.py 95.68% <0.00%> (+0.49%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 76d2102...d7fc3b9. Read the comment docs.

Copy link
Contributor

@davidhassell davidhassell left a comment

Choose a reason for hiding this comment

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

Hi Sadie - nice generalised tests. All good to go, I think.

@sadielbartholomew sadielbartholomew merged commit bb23013 into NCAS-CMS:master Mar 2, 2022
@sadielbartholomew sadielbartholomew deleted the print-no-data-other-constructs branch March 2, 2022 15:40
@davidhassell davidhassell added this to the 1.9.0.3 milestone Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
testing Issues related to units tests and their coverage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants