Beispiel #1
0
 def test_get_bmi_ranges_with_info(self):
     self.assertEqual(Bmi.get_bmi_ranges_with_info(), [
         {
             'From': 0,
             'To': 18.5,
             'Info': 'Underweight'
         },
         {
             'From': 18.5,
             'To': 25,
             'Info': 'Healthy'
         },
         {
             'From': 25,
             'To': 30,
             'Info': 'Overweight'
         },
         {
             'From': 30,
             'To': 35,
             'Info': 'Obese, Class I'
         },
         {
             'From': 35,
             'To': 40,
             'Info': 'Obese, Class II'
         },
         {
             'From': 40,
             'To': "",
             'Info': 'Obese, Class III'
         },
     ])
Beispiel #2
0
 def test_get_bmi_ranges_with_info_lang(self):
     self.assertEqual(Bmi.get_bmi_ranges_with_info("es"), [
         {
             'From': 0,
             'To': 18.5,
             'Info': 'Bajo peso'
         },
         {
             'From': 18.5,
             'To': 25,
             'Info': 'Peso saludable'
         },
         {
             'From': 25,
             'To': 30,
             'Info': 'Sobrepeso'
         },
         {
             'From': 30,
             'To': 35,
             'Info': 'Obesidad, Clase I'
         },
         {
             'From': 35,
             'To': 40,
             'Info': 'Obesidad, Clase II'
         },
         {
             'From': 40,
             'To': "",
             'Info': 'Obesidad, Clase III'
         },
     ])
Beispiel #3
0
def execute_get_bmi_ranges_with_info(args):
    return Bmi.get_bmi_ranges_with_info(args.lang)