Example #1
0
        public void GetGridForZipThatDoesNotExist()
        {
            var command = new GetAddressSystemFromZipCodeCommand(90210);

            command.Run();

            var result = command.Result;

            Assert.That(result, Is.Empty);
        }
        public void GetGridForZipThatDoesNotExist()
        {
            var command = new GetAddressSystemFromZipCodeCommand(90210);

            command.Run();

            var result = command.Result;

            Assert.That(result, Is.Empty);
        }
Example #3
0
        public void GetsMultipleItemsForZipCode()
        {
            var command = new GetAddressSystemFromZipCodeCommand(84032);

            command.Run();

            var result = command.Result;

            Assert.That(result.Count, Is.EqualTo(3));

            Assert.That(result.OrderByDescending(x => x.Weight).First().Grid, Is.EqualTo("HEBER CITY"));
        }
        public void GetsMultipleItemsForZipCode()
        {
            var command = new GetAddressSystemFromZipCodeCommand(84032);
            
            command.Run();

            var result = command.Result;

            Assert.That(result.Count, Is.EqualTo(3));

            Assert.That(result.OrderByDescending(x=>x.Weight).First().Grid, Is.EqualTo("HEBER CITY"));
        }
Example #5
0
        public void GetsGridFromZipCode()
        {
            var command = new GetAddressSystemFromZipCodeCommand(84111);

            command.Run();

            var result = command.Result;

            Assert.That(result.Count, Is.EqualTo(1));

            var first = result.FirstOrDefault();

            Assert.That(first.Grid, Is.EqualTo("SALT LAKE CITY"));
            Assert.That(first.Weight, Is.EqualTo(0));
        }
        public void GetsGridFromZipCode()
        {
            var command = new GetAddressSystemFromZipCodeCommand(84111);
            
            command.Run();

            var result = command.Result;

            Assert.That(result.Count, Is.EqualTo(1));

            var first = result.FirstOrDefault();

            Assert.That(first.Grid, Is.EqualTo("SALT LAKE CITY"));
            Assert.That(first.Weight, Is.EqualTo(0));
        }