19 #include "test_tools.h" |
19 #include "test_tools.h" |
20 #include <lemon/smart_graph.h> |
20 #include <lemon/smart_graph.h> |
21 #include <lemon/dijkstra.h> |
21 #include <lemon/dijkstra.h> |
22 #include <lemon/path.h> |
22 #include <lemon/path.h> |
23 #include <lemon/maps.h> |
23 #include <lemon/maps.h> |
24 #include <lemon/concept/graph.h> |
24 #include <lemon/concepts/graph.h> |
25 #include <lemon/concept/maps.h> |
25 #include <lemon/concepts/maps.h> |
26 using namespace lemon; |
26 using namespace lemon; |
27 |
27 |
28 const int PET_SIZE =5; |
28 const int PET_SIZE =5; |
29 |
29 |
30 |
30 |
31 void check_Dijkstra_BinHeap_Compile() |
31 void check_Dijkstra_BinHeap_Compile() |
32 { |
32 { |
33 typedef int VType; |
33 typedef int VType; |
34 typedef concept::Graph Graph; |
34 typedef concepts::Graph Graph; |
35 |
35 |
36 typedef Graph::Edge Edge; |
36 typedef Graph::Edge Edge; |
37 typedef Graph::Node Node; |
37 typedef Graph::Node Node; |
38 typedef Graph::EdgeIt EdgeIt; |
38 typedef Graph::EdgeIt EdgeIt; |
39 typedef Graph::NodeIt NodeIt; |
39 typedef Graph::NodeIt NodeIt; |
40 typedef concept::ReadMap<Edge,VType> LengthMap; |
40 typedef concepts::ReadMap<Edge,VType> LengthMap; |
41 |
41 |
42 typedef Dijkstra<Graph, LengthMap> DType; |
42 typedef Dijkstra<Graph, LengthMap> DType; |
43 |
43 |
44 Graph G; |
44 Graph G; |
45 Node n; |
45 Node n; |
68 } |
68 } |
69 |
69 |
70 void check_Dijkstra_Function_Compile() |
70 void check_Dijkstra_Function_Compile() |
71 { |
71 { |
72 typedef int VType; |
72 typedef int VType; |
73 typedef concept::Graph Graph; |
73 typedef concepts::Graph Graph; |
74 |
74 |
75 typedef Graph::Edge Edge; |
75 typedef Graph::Edge Edge; |
76 typedef Graph::Node Node; |
76 typedef Graph::Node Node; |
77 typedef Graph::EdgeIt EdgeIt; |
77 typedef Graph::EdgeIt EdgeIt; |
78 typedef Graph::NodeIt NodeIt; |
78 typedef Graph::NodeIt NodeIt; |
79 typedef concept::ReadMap<Edge,VType> LengthMap; |
79 typedef concepts::ReadMap<Edge,VType> LengthMap; |
80 |
80 |
81 Graph g; |
81 Graph g; |
82 dijkstra(g,LengthMap(),Node()).run(); |
82 dijkstra(g,LengthMap(),Node()).run(); |
83 dijkstra(g,LengthMap()).source(Node()).run(); |
83 dijkstra(g,LengthMap()).source(Node()).run(); |
84 dijkstra(g,LengthMap()) |
84 dijkstra(g,LengthMap()) |
85 .predMap(concept::WriteMap<Node,Edge>()) |
85 .predMap(concepts::WriteMap<Node,Edge>()) |
86 .distMap(concept::WriteMap<Node,VType>()) |
86 .distMap(concepts::WriteMap<Node,VType>()) |
87 .run(Node()); |
87 .run(Node()); |
88 |
88 |
89 } |
89 } |
90 |
90 |
91 |
91 |