Adding cycle tests for undirected graphs.

Cycle tests using dfs only worked for directed graphs in the past. This commit
adds the undirected graph functionality. The main change is that the 
DFSCyclicTestVisitor must now keep track of which sets of edges have been
visited.

addresses issue #41