Skip to content

Commit

Permalink
test(api): add tests for the 2 inpn_group3 routes
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxime Vergez committed Aug 7, 2023
1 parent 5a5082f commit 9747d8f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions apptax/tests/test_taxref.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,3 +102,18 @@ def test_regneGroup2Inpn_routes(self):
def test_bib_routes(self):
response = self.client.get(url_for("taxref.get_bib_hab"))
assert response.status_code == 200

def test_regneGroup2Inpn_routes(self):
response = self.client.get(url_for("taxref.get_regneGroup3Inpn_taxref"))
assert response.status_code == 200
response_json = response.json
assert "Animalia" in response_json.keys()
assert response_json["Fungi"] == ["", "Autres"]

def test_get_groupe3_inpn(self):
response = self.client.get(url_for("taxref.get_group3_inpn_taxref"))

assert response.status_code == 200
response_json = response.json
assert "Coléoptères" in response_json
assert "Autres" in response_json

0 comments on commit 9747d8f

Please sign in to comment.