Add conversion from labeled digraph to undirected.

Refactor unit tests and add print-object method on graphs.