Example #1
0
 def test_str_to_float_zero(self):
     self.assertEqual(str_to_float('0'), 0.0)
Example #2
0
 def test_str_to_float_messy(self):
     self.assertEqual(str_to_float('bb-23.34***'), -23.34)
Example #3
0
 def test_str_to_float_unparsable_input(self):
     self.assertIsNone(str_to_float('-a'))
Example #4
0
 def test_str_to_float_simple(self):
     self.assertEqual(str_to_float('-23.34'), -23.34)