static void Main(string[] args) { var fileName = args[0]; var qRepeat = 0; do { Console.Write("please enter the route:"); var route = Console.ReadLine(); var routes = route.Split('-'); var @from = routes[0]; var @to = routes[1]; var service = new BestRouteService(new RouteRepository(), new AirportRepository(), new Dijkstra()); var bestRouteInfo = service.BestRouteFromFile(fileName, @from, @to); Print(bestRouteInfo); qRepeat++; }while(qRepeat == 1); // repeat 2x block above }
public void SetUp() { findFactory = Substitute.For <IFindFactory>(); bestRoutFinder = Substitute.For <IBestRouteFinder>(); bestRouteService = new BestRouteService(findFactory); }