diff --git a/test/circulation_test.cc b/test/circulation_test.cc --- a/test/circulation_test.cc +++ b/test/circulation_test.cc @@ -57,7 +57,7 @@ typedef Digraph::Node Node; typedef Digraph::Arc Arc; typedef concepts::ReadMap CapMap; - typedef concepts::ReadMap DeltaMap; + typedef concepts::ReadMap SupplyMap; typedef concepts::ReadWriteMap FlowMap; typedef concepts::WriteMap BarrierMap; @@ -68,30 +68,42 @@ Node n; Arc a; CapMap lcap, ucap; - DeltaMap delta; + SupplyMap supply; FlowMap flow; BarrierMap bar; + VType v; + bool b; - Circulation - ::SetFlowMap - ::SetElevator - ::SetStandardElevator - ::Create circ_test(g,lcap,ucap,delta); - - circ_test.lowerCapMap(lcap); - circ_test.upperCapMap(ucap); - circ_test.deltaMap(delta); - flow = circ_test.flowMap(); - circ_test.flowMap(flow); + typedef Circulation + ::SetFlowMap + ::SetElevator + ::SetStandardElevator + ::Create CirculationType; + CirculationType circ_test(g, lcap, ucap, supply); + const CirculationType& const_circ_test = circ_test; + + circ_test + .lowerMap(lcap) + .upperMap(ucap) + .supplyMap(supply) + .flowMap(flow); + + const CirculationType::Elevator& elev = const_circ_test.elevator(); + circ_test.elevator(const_cast(elev)); + CirculationType::Tolerance tol = const_circ_test.tolerance(); + circ_test.tolerance(tol); circ_test.init(); circ_test.greedyInit(); circ_test.start(); circ_test.run(); - circ_test.barrier(n); - circ_test.barrierMap(bar); - circ_test.flow(a); + v = const_circ_test.flow(a); + const FlowMap& fm = const_circ_test.flowMap(); + b = const_circ_test.barrier(n); + const_circ_test.barrierMap(bar); + + ignore_unused_variable_warning(fm); } template