コード例 #1
0
        public void Should_Return_Shortest_Distance_Of_All()
        {
            var distances = @"London to Dublin = 464
London to Belfast = 518
Dublin to Belfast = 141".Split("\r\n");

            var distanceCalculator = new DistanceCalculator(distances);

            var result = distanceCalculator.CalculateAllShortestDistances().Values.Min();

            Assert.Equal(605, result);
        }