aazuspan / eerepr

Interactive Code Editor-style reprs for Earth Engine objects in a Jupyter notebook
MIT License
32 stars 0 forks source link

Check for unused cached test data #27

Closed aazuspan closed 1 year ago

aazuspan commented 1 year ago

Whenever a new Earth Engine object is retrieved by tests.test_html.load_info, it is saved in the tests/data/data.json cache. If an old test is removed or an unused object is accidentally committed, the cache could get out of sync with the tests.

It would be easy enough to fix this just by resetting the cache, but the ideal solution for long term maintenance would be to check that each object is actually used by the tests and either warn the user or delete any objects that aren't used. This may be tricky, especially in cases where a user runs a subset of tests, but it's worth poking around to see if there's a simple solution for this.