def test_path(self): (lengths, prev) = bellman_ford(self.graph, 0) self.assertEqual(util.get_path_from_prev(prev, 8), [0, 1, 2])
def test_path(self): (lengths, prev) = dijkstra(self.graph, 0) self.assertEqual(util.get_path_from_prev(prev, 8), [0, 1, 2])