Lots more work on test cleanup