Skip to content

Commit

Permalink
modify test_ARAX_expand:test_xdtd_expand to avoid errors from some xd…
Browse files Browse the repository at this point in the history
…td predictions without supported graphs
  • Loading branch information
chunyuma committed Mar 29, 2024
1 parent 4e99d65 commit 048f8f7
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions code/ARAX/test/test_ARAX_expand.py
Original file line number Diff line number Diff line change
Expand Up @@ -1123,10 +1123,12 @@ def test_xdtd_expand():
if inferred_edge:
assert edge.attributes
support_graph_attributes = [attribute for attribute in edge.attributes if attribute.attribute_type_id == "biolink:support_graphs"]
assert support_graph_attributes
assert len(support_graph_attributes) == 1
support_graph_attribute = support_graph_attributes[0]
assert support_graph_attribute.value[0] in message.auxiliary_graphs
## some xdtd predictions don't have support_graphs, so skip them
if len(support_graph_attributes) > 0:
assert support_graph_attributes
assert len(support_graph_attributes) == 1
support_graph_attribute = support_graph_attributes[0]
assert support_graph_attribute.value[0] in message.auxiliary_graphs


@pytest.mark.slow
Expand Down

0 comments on commit 048f8f7

Please sign in to comment.