Skip to content
This repository has been archived by the owner on Apr 7, 2022. It is now read-only.

Commit

Permalink
Tests for grouping cluster candu graphs by tags
Browse files Browse the repository at this point in the history
  • Loading branch information
nachandr committed Apr 11, 2019
1 parent 279db12 commit ead747a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cfme/tests/candu/test_graph_groupbytag.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,15 @@ def test_tagwise(candu_db_restore, interval, graph_type, gp_by, entity, entity_o
data = {'interval': interval, 'group_by': gp_by}
view.options.fill(data)

graph_zoom = ["cluster_host", "cluster_vm"]
avg_graph = graph_type if graph_type in graph_zoom else "{}_vm_host_avg".format(graph_type)

# Check graph displayed or not
try:
graph = getattr(view.interval_type, entity + '_' + graph_type)
if entity == 'host':
graph = getattr(view.interval_type, entity + '_' + graph_type)
elif entity == 'cluster':
avg_graph = getattr(view, avg_graph)
except AttributeError:
pytest.fail('{}_{} graph was not displayed'.format(entity, graph_type))
assert graph.is_displayed
Expand Down

0 comments on commit ead747a

Please sign in to comment.