filecoin-project / rust-fil-proofs

Proofs for Filecoin in Rust
Other
489 stars 314 forks source link

feat: properly remove temporary files leftover after running tests #1762

Open cryptonemo opened 2 weeks ago

cryptonemo commented 2 weeks ago

Take 2: It took a while to track down which tests were leaving around .tmp* directories and files in the TEMPDIR after the test suite was run, but it appears that this resolves them all across normal and 'ignored' tests.

In short, if there are any open files/dirs remaining when TempDir is scoped out, a deletion is silently omitted. This code more explicitly cleans up some temporary artifacts in order to ensure everything is removed and closed before that happens.