Exemplo n.º 1
0
        public void WhatAreTheNumberOfTrips_StartingAtCAndEndingAtC_WithAMaximumOfThreeHops(string graphInput, int expectation)
        {
            //arrange
            var graph = new Graph(graphInput);

            //act
            var tripResponse = new MaxStopTripFinder(graph).FindTrip('C', 'C');

            //assert
            Assert.That(tripResponse.GetResponse(), Is.EqualTo(expectation.ToString()));
        }
Exemplo n.º 2
0
        private static void DoMaxTripFinder(Graph graph, List<IResponse> responses)
        {
            var maxTripFinder = new MaxStopTripFinder(graph);

            responses.Add(maxTripFinder.FindTrip('C', 'C'));
        }