fixed bugs with thermometer and tests