Format Python source and tests
This commit is contained in:
parent
45dc2c2e67
commit
fb9bb532ec
8 changed files with 31 additions and 22 deletions
|
|
@ -83,14 +83,14 @@ def test_example(app_ctx, mocker, i: int, lat: float, lon: float, name: str) ->
|
|||
expected_cat = fixture["expected_commons_cat"]
|
||||
if expected_cat:
|
||||
commons = result.get("commons_cat")
|
||||
assert isinstance(commons, dict), (
|
||||
f"{name}: expected commons_cat={expected_cat!r} but result has none"
|
||||
)
|
||||
assert isinstance(
|
||||
commons, dict
|
||||
), f"{name}: expected commons_cat={expected_cat!r} but result has none"
|
||||
assert commons["title"] == expected_cat, (
|
||||
f"{name}: commons_cat mismatch — expected {expected_cat!r}, "
|
||||
f"got {commons['title']!r}"
|
||||
)
|
||||
else:
|
||||
assert not result.get("commons_cat"), (
|
||||
f"{name}: expected no commons_cat but got {result.get('commons_cat')!r}"
|
||||
)
|
||||
assert not result.get(
|
||||
"commons_cat"
|
||||
), f"{name}: expected no commons_cat but got {result.get('commons_cat')!r}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue