tests: makeFileUpload: Use unittest addCleanup() to close files rather than tearDown().
This executes even if setup() encounters an error and the cleanup hook is added
when opening the file, not later on.
Also, unify makeFileUpload() and makeFilePath() to remove duplicated code.
Co-authored-by: Arnaud Fontaine <arnaud.fontaine@nexedi.com>
Showing
Please register or sign in to comment