astropy/astropy — pull request #673 by mdboom (2013-01-24 19:22:16+00:00)
Title: Adds "unclosed file detection" to the test framework using lsof

This is an alternative to #450 that calls out to `lsof` to find the files opened by the process.

It's much slower, so it's an option (`--open-files`), but it seems to work, and it doesn't care whether the file was closed explicitly or implicitly (for better or worse).