public virtual ApiFollowingServerRequestModel MapServerResponseToRequest(
            ApiFollowingServerResponseModel response)
        {
            var request = new ApiFollowingServerRequestModel();

            request.SetProperties(
                response.DateFollowed,
                response.Muted);
            return(request);
        }
Пример #2
0
        public void MapModelToEntity()
        {
            var mapper = new DALFollowingMapper();
            ApiFollowingServerRequestModel model = new ApiFollowingServerRequestModel();

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

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