Example #1
0
 def test_convert_height(self):
     """Test height conversion from cm to cm or feet"""
     units = (('cm', 1),
              ('feet', 0.032808399))
     for unit in units:
         new_height = util.convert_height(1, unit[0])
         self.assertEqual(new_height, unit[1],
                          "Incorrect conversion result from cm to " + unit[0])
Example #2
0
 def height( self ):
     return convert_height(self.height_cm, self.height_uom)
Example #3
0
 def height(self):
     return convert_height(self.height_cm, self.height_uom)