Skip to content

Commit

Permalink
Increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike committed Oct 31, 2023
1 parent c268191 commit 45cb0a2
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions tests/hdx/location/test_adminlevel.py
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,13 @@ def test_adminlevel_pcode_formats(self, config, url, formats_url):

admintwo = AdminLevel(config, admin_level=2)
admintwo.setup_from_url(admin_url=url)
assert admintwo.get_pcode(
"YEM", "YE03001", logname="test", fuzzy_match=False
) == (
None,
True,
)

admintwo.load_pcode_formats(formats_url=formats_url)
assert admintwo.get_pcode("YEM", "YE3001", logname="test") == (
"YE3001",
Expand Down Expand Up @@ -440,13 +447,11 @@ def test_adminlevel_pcode_formats(self, config, url, formats_url):
)

admintwo.set_parent_admins([adminone.pcodes])
assert admintwo.get_pcode("NER", "NE00409", logname="test") == (
"NER004009",
assert admintwo.get_pcode("YEM", "YEM03001", logname="test") == (
"YE3001",
True,
)
assert admintwo.get_pcode(
"COL", "CO080849", logname="test", fuzzy_match=False
) == (
"CO08849",
assert admintwo.get_pcode("NGA", "NG1501", logname="test") == (
"NG015001",
True,
)

0 comments on commit 45cb0a2

Please sign in to comment.