openradar / xradar

A tool to work in weather radar data in xarray
https://docs.openradarscience.org/projects/xradar
MIT License
85 stars 17 forks source link

MIN: restructure odim.py/gamic.py, add test_odim.py/test_gamic.py #154

Closed kmuehlbauer closed 4 months ago

kmuehlbauer commented 4 months ago

Restructure and add tests for _OdimH5NetCDFMetadata/_GamicH5NetCDFMetadata. Refactor out _H5NetCDFMetadata as parent class.

codecov[bot] commented 4 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 89.91%. Comparing base (236bafd) to head (cb3ab83). Report is 1 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #154 +/- ## ========================================== + Coverage 88.33% 89.91% +1.57% ========================================== Files 20 20 Lines 3439 3421 -18 ========================================== + Hits 3038 3076 +38 + Misses 401 345 -56 ``` | [Flag](https://app.codecov.io/gh/openradar/xradar/pull/154/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openradar) | Coverage Δ | | |---|---|---| | [notebooktests](https://app.codecov.io/gh/openradar/xradar/pull/154/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openradar) | `0.00% <0.00%> (?)` | | | [unittests](https://app.codecov.io/gh/openradar/xradar/pull/154/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openradar) | `89.91% <100.00%> (+1.57%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=openradar#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

mgrover1 commented 4 months ago

@kmuehlbauer let me know when you need a review here!

kmuehlbauer commented 4 months ago

Thanks @mgrover1, it's still in the works. Combining this with gamic.py. I'll let you know, when this is ready for review.

mgrover1 commented 4 months ago

Sounds good :) exciting stuff!

kmuehlbauer commented 4 months ago

@mgrover1 This is ready for review. Essentially this is just a heavy refactor of the odim/gamic backend code with added tests.

Test coverage increased by almost 1%. When this is merged I'll try to cover the last missing lines (at least for odim/gamic).

kmuehlbauer commented 4 months ago

@mgrover1 Pushed some more code which fit's in here. I'll leave this now as is for your review.

kmuehlbauer commented 4 months ago

Thanks @mgrover1, let's get this refactor in. The next changes won't be that voluminous.