mirror of
https://github.com/enzet/map-machine.git
synced 2025-04-29 18:27:19 +02:00
Add test for empty ways.
This commit is contained in:
parent
5fc9ab0b5e
commit
701263f065
1 changed files with 9 additions and 0 deletions
|
@ -44,3 +44,12 @@ def test_river_and_wood() -> None:
|
|||
assert len(figures) == 2
|
||||
assert figures[0].tags["natural"] == "wood"
|
||||
assert figures[1].tags["waterway"] == "river"
|
||||
|
||||
|
||||
def test_empty_ways() -> None:
|
||||
"""Ways without nodes."""
|
||||
osm_data: OSMData = OSMData()
|
||||
osm_data.add_way(OSMWay({"natural": "wood"}, 1))
|
||||
osm_data.add_way(OSMWay({"waterway": "river"}, 2))
|
||||
|
||||
assert not get_constructor(osm_data).get_sorted_figures()
|
||||
|
|
Loading…
Add table
Reference in a new issue