No-ticket: Ensures open files to be closed and fix for failing test with WARC file.