mirror of
https://github.com/biopython/biopython.git
synced 2025-10-20 13:43:47 +08:00
Tweak f-string to avoid flake8 E226
❯ flake8 Tests/test_Phylo_igraph.py Tests/test_Phylo_igraph.py:34:34: E226 missing whitespace around arithmetic operator Perhaps we should explicitly add E226 to our flake8 ignore? Ruff didn't mind either way.
This commit is contained in:
committed by
Peter Cock
parent
ce36b82cdd
commit
4a220bd6a9
@ -31,7 +31,7 @@ class UtilTests(unittest.TestCase):
|
|||||||
"""Tree to Graph conversion, simple tree."""
|
"""Tree to Graph conversion, simple tree."""
|
||||||
tree = Phylo.read(StringIO("()()"), format="newick")
|
tree = Phylo.read(StringIO("()()"), format="newick")
|
||||||
for i, elem in enumerate(tree.find_clades()):
|
for i, elem in enumerate(tree.find_clades()):
|
||||||
elem.name = f"elem_{i+1}"
|
elem.name = f"elem_{i + 1}"
|
||||||
elem.width = f"width_{i}"
|
elem.width = f"width_{i}"
|
||||||
graph = Phylo.to_igraph(tree, vertex_attributes=["name"])
|
graph = Phylo.to_igraph(tree, vertex_attributes=["name"])
|
||||||
self.assertEqual(graph.vs["name"], ["elem_1", "elem_2", "elem_3"])
|
self.assertEqual(graph.vs["name"], ["elem_1", "elem_2", "elem_3"])
|
||||||
|
Reference in New Issue
Block a user