Michael refactored unit tests