Closed georgievgeorgi closed 2 months ago
Click to see where and how coverage changed
File Statements Missing Coverage Coverage
(new stmts)Lines missing
src/ramanchada2/misc/utils
argmin2d.py
67
src/ramanchada2/spectrum/baseline
add_baseline.py
src/ramanchada2/spectrum/filters
add_gaussian_noise.py
add_gaussian_noise_drift.py
add_poisson_noise.py
tests/misc
test_argmin2d_align.py
tests/spectrum
test_random_generator_seeds.py
Project Total
This report was generated by python-coverage-comment-action
TODO: make sure it works with numpy 1
please check if it works with both numpy<2 & numpy>=2
All the tests pass successfully with both numpy<2 and numpy>=2. So the PR seems safe to be merged.
@georgievgeorgi Thank you very much for the work on this! Do you think it is realistic to cover with tests the few remaining statements per the coverage report above?
In the tests i found that i doubled the tests for add_gaussian_noise
and missed the add_poisson_noise
(@kerberizer, thank you for drawing my attention there). Currently i am playing with tests for argmin2d
.
@kerberizer, could you please review and merge this pull request
@georgievgeorgi I was under the impression that you wanted to add more tests. Are we going to aim for 100% test coverage? It's one single statement, but still.
I understand. I fixed a copy-paste issue and added an extra test which covers argmin2d
. Adding a test for align_shift
, however, is not that straight forward. With the provided tests the code coverage is improved anyway and as the main purpose of the pull request is not to provide tests but to fix the numpy2 issues, i think it can be merged.
np.infty
substituted withnp.inf
rng.bit_generator.state
to get and set states