Open melissalinkert opened 1 month ago
A good starting point for this might be the logic in https://github.com/ome/bioformats/blob/1f03e09e22b0958f1e947669836650e842fed6b2/components/test-suite/src/loci/tests/testng/FormatReaderTest.java#L2973-L3001.
This feature was been introduced in https://github.com/ome/bioformats/pull/3159 to identify whether the included changes are backwards-incompatible with memo files created by the previous release of Bio-Formats and decide whether the next release should increment the patch or minor version.
Functionality was also introduced to create cache files for all configured datasets included in the nightly repository tests. The location of this cache directory could be passed to the Ant target via -Dtestng.cacheDirectory
.
Something that might need to be reviewed if we are looking into reusing the existing logic is that testMemoFileUsage
would currently fail if there are any backwards-incompatible serialization changes that invalidate the previous memo file.
https://github.com/ome/bioformats/pull/4234 highlights that there can be cases where memo file loading breaks in a way that our current tests do not catch. Catching these issues by eye in code review is possible, but very easy to overlook.
One approach would be to store memo files generated from the previous released version in https://github.com/openmicroscopy/data_repo_config. Then we could add a test similar to https://github.com/ome/bioformats/blob/develop/components/test-suite/src/loci/tests/testng/FormatReaderTest.java#L2943 that reads the stored memo file.