You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Following PR #114 the plotting functions need unit tests. @astronomerritt's suggestions:
Run the function several times testing each if-statement (so one that uses label_list, one that uses col_list, one accepting fig as an argument). You don't have to check the resultant plots - the aim of the unit test is to make sure that no errors trigger when the function is called. That way, if anything changes in the code that would break plotting entirely, we'll know.
Create a plot using savefig then check that it exists where you told it to save using os.path.exists(). Using pytest's tmp_path functionality is helpful here to direct output of tests to a temporary location. You can see how that's done in test_AdlerData.py in the test test_write_row_to_database().
The text was updated successfully, but these errors were encountered:
Following PR #114 the plotting functions need unit tests. @astronomerritt's suggestions:
The text was updated successfully, but these errors were encountered: