public void OriginAndDestinationWithSameAddress()
        {
            IEnumerable <IAddress> addresses = new List <IAddress>
            {
                _modelFactory.Create("Avenida Paulista", "1000", "São Paulo", "SP"),
                _modelFactory.Create("Avenida Paulista", "1000", "São Paulo", "SP"),
            };

            var routeTotal = _calculateTotalOfRouteService.GetTotalValuesOfRoute(addresses, 0);

            routeTotal.Should().Not.Be.Null();
            routeTotal.TotalCost.Should().Be(0);
            routeTotal.TotalDistance.Should().Be(0);
            routeTotal.TotalfuelCost.Should().Be(0);
            routeTotal.TotalTime.Should().Not.Be.Empty();
        }
示例#2
0
        public void OnlyOneAddress()
        {
            IEnumerable <IAddress> addresses = new List <IAddress>
            {
                _modelFactory.Create("Avenida Paulista", "1000", "São Paulo", "SP")
            };

            _calculateTotalOfRouteService.GetTotalValuesOfRoute(addresses, 0);
        }