Improved tests for util/acyclicTraversal.