Test fixes

Small fixes to make the test suite cleaner.