Cleaned up some of the code for the sanitation tests