Skip to content

Commit

Permalink
fix (occhab,test) : apply export column renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
jacquesfize committed Jul 18, 2024
1 parent 3c7d825 commit 95d9b15
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions backend/geonature/tests/test_pr_occhab.py
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ def test_export_occhab(self, stations, users):
# Read the CSV and verify all declared stations are contained in the export
uuids_INPN_export = pd.read_csv(
StringIO(response.data.decode("utf-8")), sep=";"
).identifiantStaSINP.unique()
).uuid_station.unique()
assert all([True if uuid_ in uuids_INPN_export else False for uuid_ in uuidINPN])

# Test the GEOJSON export
Expand All @@ -591,8 +591,7 @@ def test_export_occhab(self, stations, users):
assert response.status_code == 200
# READ the GEOJson and check if all stations INPN uuid are present
uuids_INPN_export = [
item["properties"]["identifiantStaSINP"]
for item in json.loads(response.data)["features"]
item["properties"]["uuid_station"] for item in json.loads(response.data)["features"]
]
assert all([True if uuid_ in uuids_INPN_export else False for uuid_ in uuidINPN])

Expand Down

0 comments on commit 95d9b15

Please sign in to comment.