Clean unittest code