Refactor a few more tests and cleaned up the output in some situations