Fix tests

* Some tests were broken (`expect` missing conditions).
* No test cleaned up afterwards.

This fixes both problems.