better cleanup in tests