breken-ai commented on PR #938:
URL: https://github.com/apache/burr/pull/938#issuecomment-6049611198
@CanReader thanks for testing it. I did both in bdf29b5:
- **App-level test:** `test_application_visualize_edge_attr` builds an app
with `ApplicationBuilder().with_graph(graph)` and checks that
`app.visualize(edge_attr={"color": "red"})` sets `edge_attr` and keeps
`rankdir="TB"`.
- **`None` attrs:** in `Graph.visualize`, a `None` value for a `*_attr` key
is now skipped, the same as not passing it. So `graph_attr=None` keeps
`rankdir`, `ranksep` and the rest. I limited the skip to `*_attr` keys so that
other Digraph kwargs such as `encoding=None` still go through unchanged.
`test_visualize_none_attr_keeps_defaults` covers this.
Red/green:
- main @ `8161159`: all three new tests fail. Two fail with `KeyError:
'edge_attr'`, and the `None` test fails on the wiped `graph_attr`.
- Previous head `2b1600d`: only `test_visualize_none_attr_keeps_defaults`
fails.
- This head: `tests/core` is 403 passed. `black --line-length=100`, `isort`
and `flake8` are clean on the changed files.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]