earthlab / matplotcheck

A python package for checking and testing matplotlib plots. We use this for autograding student assignments but there are many other potential use cases including package testing (for packages with plots)!
https://matplotcheck.readthedocs.io
BSD 3-Clause "New" or "Revised" License
18 stars 8 forks source link

Hist bin midpoints #204

Closed nkorinek closed 4 years ago

nkorinek commented 4 years ago

Added two new functions, get_bin_midpoints() and assert_bin_midpoints() to the PlotTester object in order to cover testing requested in this issue: https://github.com/earthlab/matplotcheck/issues/184 . Added tests and documentation for these new arguments as well.

codecov[bot] commented 4 years ago

Codecov Report

Merging #204 into master will not change coverage by %. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #204   +/-   ##
=======================================
  Coverage   79.90%   79.90%           
=======================================
  Files          19       19           
  Lines        1826     1826           
=======================================
  Hits         1459     1459           
  Misses        367      367           

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 dcbe2ad...dcbe2ad. Read the comment docs.

lwasser commented 4 years ago

@nkorinek what does this do for us? can you add some example application to our histogram vignette so i can better understand and see how it works? https://matplotcheck.readthedocs.io/en/latest/gallery_vignettes/plot_histogram_testing.html#sphx-glr-gallery-vignettes-plot-histogram-testing-py

nkorinek commented 4 years ago

@lwasser I added the functionality to the histogram vignette to clarify what it does. As far as what it does for us, I believe it adds the functionality that was requested in this issue https://github.com/earthlab/matplotcheck/issues/184 If I misunderstood the issue and this is not what you were looking for please let me know so I can change course!

nkorinek commented 4 years ago

@lwasser changes are in!

nkorinek commented 4 years ago

@lwasser this is passing everything, but appveyor failed and doesn't have a details tab? I haven't seen that before and I'm not sure how to fix it.

lwasser commented 4 years ago

@nkorinek i'm seeing green on everything? where is the error that you're seeing? it seems good to me but please confirm that i'm not missing something. if i'm not we can merge this puppy!!

nkorinek commented 4 years ago

@lwasser it was failing, but it's been fixed now, weird! Looks good to go, I just fixed the CHANGELOG merge conflict.

lwasser commented 4 years ago

great. @nkorinek sometimes appveyor is finicky and just needs to rebuild. i'm not really sure why. but i'll merge this one CI finishes. looks like travis is still going here.