def test_sg_breadth_first_traversal_empty(): """Ensure an empty result is handed back when called on empty graph.""" from simple_graph import SimpleGraph test_sg = SimpleGraph() with pytest.raises(IndexError) as message: test_sg.breadth_first_traversal("a") assert "That starting point is not in the graph." in str(message)