Exemplo n.º 1
0
        public void MapBOToModelList()
        {
            var           mapper = new BOLAddressTypeMapper();
            BOAddressType bo     = new BOAddressType();

            bo.SetProperties(1, DateTime.Parse("1/1/1987 12:00:00 AM"), "A", Guid.Parse("8420cdcf-d595-ef65-66e7-dff9f98764da"));
            List <ApiAddressTypeResponseModel> response = mapper.MapBOToModel(new List <BOAddressType>()
            {
                { bo }
            });

            response.Count.Should().Be(1);
        }
Exemplo n.º 2
0
        public void MapBOToModel()
        {
            var           mapper = new BOLAddressTypeMapper();
            BOAddressType bo     = new BOAddressType();

            bo.SetProperties(1, DateTime.Parse("1/1/1987 12:00:00 AM"), "A", Guid.Parse("8420cdcf-d595-ef65-66e7-dff9f98764da"));
            ApiAddressTypeResponseModel response = mapper.MapBOToModel(bo);

            response.AddressTypeID.Should().Be(1);
            response.ModifiedDate.Should().Be(DateTime.Parse("1/1/1987 12:00:00 AM"));
            response.Name.Should().Be("A");
            response.Rowguid.Should().Be(Guid.Parse("8420cdcf-d595-ef65-66e7-dff9f98764da"));
        }