public virtual ApiFamilyServerRequestModel MapServerResponseToRequest( ApiFamilyServerResponseModel response) { var request = new ApiFamilyServerRequestModel(); request.SetProperties( response.Notes, response.PrimaryContactEmail, response.PrimaryContactFirstName, response.PrimaryContactLastName, response.PrimaryContactPhone); return(request); }
public void MapModelToEntity() { var mapper = new DALFamilyMapper(); ApiFamilyServerRequestModel model = new ApiFamilyServerRequestModel(); model.SetProperties("A", "A", "A", "A", "A"); Family response = mapper.MapModelToEntity(1, model); response.Notes.Should().Be("A"); response.PrimaryContactEmail.Should().Be("A"); response.PrimaryContactFirstName.Should().Be("A"); response.PrimaryContactLastName.Should().Be("A"); response.PrimaryContactPhone.Should().Be("A"); }