Cleaned code indenting up a bit, and added docstring
Added tests for test_average_shortest_path_length_weakly_connected:

- Gives same answer as test_average_shortest_path_length_weakly_connected when
invoked on an undirected graph.

- In the case of a linear cascade, 1->2->3->4 gives the correct answer.