Add test pointing out a pre-traverse problem
Fix `pre-traverse` to pass the failing test

There are special cases such as this:

    :a
   / | \
  v  v  v
 :e :b :c
  |     ^
  |    /
  |   /
  |  /
  | /
  |/
  v
 :d

in which the function yields false traverse. The error comes from the
fact that after discovering :a the algorithm marks its direct successors
:e, :b and :c as discovered. Therefore if the algorithm starts at :a
then chooses to visit :e, then :d it will start backtracking instead of
visiting :c because the vertex :c is marked as visited. If the
successors of :a are visited in the order (:e :b :c) then the result
would be (:a :e :d :b :c), which is obviously incorrect.
Rewrite the test to respect the established style
Merge pull request #38 from gshopov/pre-traverse-fix

Pre traverse fix