Exemplo n.º 1
0
        public virtual ApiScrapReasonResponseModel MapBOToModel(
            BOScrapReason boScrapReason)
        {
            var model = new ApiScrapReasonResponseModel();

            model.SetProperties(boScrapReason.ScrapReasonID, boScrapReason.ModifiedDate, boScrapReason.Name);

            return(model);
        }
Exemplo n.º 2
0
        public void MapResponseToRequest()
        {
            var mapper = new ApiScrapReasonModelMapper();
            var model  = new ApiScrapReasonResponseModel();

            model.SetProperties(1, DateTime.Parse("1/1/1987 12:00:00 AM"), "A");
            ApiScrapReasonRequestModel response = mapper.MapResponseToRequest(model);

            response.ModifiedDate.Should().Be(DateTime.Parse("1/1/1987 12:00:00 AM"));
            response.Name.Should().Be("A");
        }