Skip to content

Commit

Permalink
Address failing tests
Browse files Browse the repository at this point in the history
Disable Google test if credentials are missing.

Not sure what was wrong with the Philadelphia address for Census
purposes, but switching to an Alexandria address fixes that.
  • Loading branch information
rajadain committed Jan 22, 2024
1 parent 99f6963 commit de75706
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions omgeo/tests/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ def test_esri_short_region(self):
candidate = self.g_esri_wgs.get_candidates(self.pq["azavea"])[0]
self.assertEqual(candidate.match_region, "PA")

@unittest.skipIf(GOOGLE_API_KEY is None, GOOGLE_KEY_REQUIRED_MSG)
def test_google_short_region(self):
"""Ensure that Google uses region abbreviations"""
candidate = self.g_google.get_candidates(self.pq["azavea"])[0]
Expand Down Expand Up @@ -282,8 +283,8 @@ def test_geocode_nom(self):
self.assertEqual(len(candidates) > 0, True, 'No candidates returned.')

def test_geocode_census(self):
"""Test Azavea's address using US Census geocoder."""
candidates = self.g_census.get_candidates(PlaceQuery('1200 Callowhill St, Philadelphia, PA'))
"""Test Element 84's address using US Census geocoder."""
candidates = self.g_census.get_candidates(PlaceQuery('210 N. Lee Street, Alexandria, VA'))
self.assertEqual(len(candidates) > 0, True, 'No candidates returned.')

def test_EsriWGS_address_components(self):
Expand Down

0 comments on commit de75706

Please sign in to comment.