Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
martinfleis committed Apr 8, 2022
1 parent b9aaccd commit 2024927
Showing 1 changed file with 9 additions and 15 deletions.
24 changes: 9 additions & 15 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,11 @@ def test_gdf_to_nx(self):
)

dual = mm.gdf_to_nx(self.df_streets, approach="dual", angle="ang")
assert (
dual.edges[
(1603499.42326969, 6464328.7520580515),
(1603510.1061735682, 6464204.555117119),
0,
]
== {"ang": 117.18288698243317}
)
assert dual.edges[
(1603499.42326969, 6464328.7520580515),
(1603510.1061735682, 6464204.555117119),
0,
] == {"ang": 117.18288698243317}

dual = mm.gdf_to_nx(
self.df_streets, approach="dual", angles=False, multigraph=False
Expand All @@ -85,13 +82,10 @@ def test_gdf_to_nx(self):

dual = mm.gdf_to_nx(self.df_streets, approach="dual", multigraph=False)
assert isinstance(nx, networkx.Graph)
assert (
dual.edges[
(1603499.42326969, 6464328.7520580515),
(1603510.1061735682, 6464204.555117119),
]
== {"angle": 117.18288698243317}
)
assert dual.edges[
(1603499.42326969, 6464328.7520580515),
(1603510.1061735682, 6464204.555117119),
] == {"angle": 117.18288698243317}

with pytest.raises(ValueError):
mm.gdf_to_nx(self.df_streets, approach="dual", directed=True)
Expand Down

0 comments on commit 2024927

Please sign in to comment.