Beispiel #1
0
 def test_zero_results_handling(self):
     '''ensure geocoding wrapper gracefully handles zero results returned'''
     response = GoogleGeocodingResponse(self._open_test_json('zero-results.json'))
     self.assertEquals(len(response.results),0)
     self.assertIsNone(response.best_result(),None)
Beispiel #2
0
 def test_zero_results_handling(self):
     '''ensure geocoding wrapper gracefully handles zero results returned'''
     response = GoogleGeocodingResponse(
         self._open_test_json('zero-results.json'))
     self.assertEquals(len(response.results), 0)
     self.assertIsNone(response.best_result(), None)
Beispiel #3
0
 def _json_to_best_result(self,fn):
     response = GoogleGeocodingResponse(self._open_test_json(fn))
     return response.best_result(wrapped=True)
Beispiel #4
0
 def _json_to_best_result(self, fn):
     response = GoogleGeocodingResponse(self._open_test_json(fn))
     return response.best_result(wrapped=True)