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

Lines testing -- MPC current tests ALL LINES #263

Open lwasser opened 4 years ago

lwasser commented 4 years ago

As it stands, assert_lines currently loops through all lines int he plot and checks to see if one of them matches the criteria : for example a 1:1 line. We may want to think about mapping lines to colors or styles (dashed, etc) for future to make the check more specific.

nkorinek commented 4 years ago

@lwasser hey! Correct me if I'm wrong, but is this not what assert_lines_grouped_by_type tests? It uses the function get_lines_by_attributes, which gets lines in groups based off of their color, linewidth, and linestyle, and than tests that the geometries match for each grouping of lines. Let me know if I'm misunderstanding what you're asking here!