diff -r 81e89e2b90d1 -r fc20371677b9 src/test/dfs_test.cc --- a/src/test/dfs_test.cc Thu Mar 31 13:30:27 2005 +0000 +++ b/src/test/dfs_test.cc Thu Mar 31 13:31:39 2005 +0000 @@ -17,6 +17,7 @@ #include "test_tools.h" #include #include +#include #include using namespace lemon; @@ -56,6 +57,8 @@ // pn = dfs_test.predNodeMap(); b = dfs_test.reached(n); + DirPath pp(G); + dfs_test.getPath(pp,n); } @@ -102,6 +105,10 @@ Dfs dfs_test(G); dfs_test.run(s); + DirPath p(G); + check(dfs_test.getPath(p,t),"getPath() failed to set the path."); + check(p.length()==dfs_test.dist(t),"getPath() found a wrong path."); + for(NodeIt v(G); v!=INVALID; ++v) { check(dfs_test.reached(v),"Each node should be reached."); if ( dfs_test.pred(v)!=INVALID ) {