Esempio n. 1
0
 def testNoMax(self):
     with self.assertRaises(NoMaxError) as context:
         calc_pka(
             read_csv(NO_MAX_RAD_PATH,
                      data_conv={
                          FREE_KEY: float,
                          CORR_KEY: float,
                          COORD_KEY: float,
                      }), calc_kbt(EXP_TEMP))
     self.assertTrue(NO_MAX_ERR in context.exception.args)
Esempio n. 2
0
 def testGood(self):
     pka_val = calc_pka(
         read_csv(GOOD_RAD_PATH,
                  data_conv={
                      FREE_KEY: float,
                      CORR_KEY: float,
                      COORD_KEY: float,
                  }), calc_kbt(EXP_TEMP))
     self.assertAlmostEqual(4.7036736, pka_val[0])
Esempio n. 3
0
 def testNoMax(self):
     with self.assertRaises(NoMaxError) as context:
         calc_pka(read_csv(NO_MAX_RAD_PATH,
                           data_conv={FREE_KEY: float, CORR_KEY: float, COORD_KEY: float, }),
                  calc_kbt(EXP_TEMP))
     self.assertTrue(NO_MAX_ERR in context.exception.args)
Esempio n. 4
0
 def testGood(self):
     pka_val = calc_pka(read_csv(GOOD_RAD_PATH,
                                 data_conv={FREE_KEY: float, CORR_KEY: float, COORD_KEY: float, }),
                        calc_kbt(EXP_TEMP))
     self.assertAlmostEqual(4.7036736, pka_val[0])