Places third party imports after standard libraries
Adds tests for/fixes nonexistent stream reading/deletions