Skip to content

Commit

Permalink
Re-adding port + setup changes
Browse files Browse the repository at this point in the history
final changes (I hope!) to setup module + re-adding the port since the test did not work without it.
  • Loading branch information
nataliejschultz committed Oct 31, 2023
1 parent 3bf52de commit 8c2efb0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions emission/individual_tests/TestNominatim.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def setUp(self):
write_ts = 1694344333
data = {'source': 'FakeTripGenerator','location': {'type': 'Point', 'coordinates': [-71.4128343, 41.8239891]}}
fake_place = ecwe.Entry.create_fake_entry(fake_id, key, data, write_ts)
return fake_place
self.fake_place = fake_place

#When a nominatim service is called, we set the value of the NOMINATIM_QUERY_URL environment variable in nominatim.py and re-load the module.
def nominatim(service):
Expand Down Expand Up @@ -60,7 +60,7 @@ def test_geofabrik_and_nominatim(self):
#Checks the display name generated by get_filtered_place in clean_and_resample.py, which creates a cleaned place from the fake place
# and reverse geocodes with the coordinates.
def test_get_filtered_place(self):
fake_place_raw = self.setUp()
fake_place_raw = self.fake_place
fake_place_data = clean.get_filtered_place(fake_place_raw).__getattr__("data")
actual_result = fake_place_data.__getattr__("display_name")
expected_result = "Dorrance Street, Providence"
Expand Down
4 changes: 3 additions & 1 deletion emission/integrationTests/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
- GFBK_KEY=$GFBK_KEY
- GEOFABRIK_QUERY_URL=https://geocoding.geofabrik.de/$GFBK_KEY
- OPENSTREETMAP_QUERY_URL=https://nominatim.openstreetmap.org
- NOMINATIM_CONTAINER_URL=http://rhodeisland-nominatim
- NOMINATIM_CONTAINER_URL=http://rhodeisland-nominatim:8080

volumes:
# specify the host directory where the source code should live
Expand Down Expand Up @@ -41,6 +41,8 @@ services:
entrypoint: /app/start.sh
image: nataliejschultz/rhodeisland-image:4.0
container_name: rhodeisland-nominatim
ports:
- "8080:8080"
deploy:
replicas: 1
restart_policy:
Expand Down

0 comments on commit 8c2efb0

Please sign in to comment.