public static void CapturePropertiesForAdd(ProviderV2 source, Provider provider) { provider.Npi = (string.IsNullOrEmpty(source.Npi) ? null : (long?)long.Parse(source.Npi, CultureInfo.InvariantCulture)) ?? provider.Npi; provider.SetName(source.NamePrefix, source.FirstName, source.MiddleName, source.LastName, source.NameSuffix, source.AdditionalSuffix); provider.AdditionalInformation = source.AdditionalInformation; provider.SetDateOfBirth(ConvertToNullibleDateTime(source.DateOfBirth, null, "DateOfBirth", provider.FullName)); provider.SetEmail(source.Email); provider.SetFax(source.Fax); provider.SetInPracticeSince(ConvertToNullibleDateTime(source.InPracticeSince, null, "InPracticeSince", provider.FullName)); provider.IsEnabled = ConvertToBool(source.IsEnabled, true, "IsEnabled", provider.FullName); provider.PhilosophyOfCare = source.PhilosophyOfCare; provider.SetPhone(source.Phone); provider.SetWebsite(source.Website); provider.SetAboutMe(source.AboutMe); provider.VideoContent = source.VideoContent; provider.UpdatedDate = DateTime.UtcNow; provider.Keywords = source.Keywords; provider.CustomKeywords = source.CustomKeywords; provider.ExcludedKeywords = source.ExcludedKeywords; provider.ImageUrl = source.ImageUrl; provider.PictureId = ConvertToNullibleInt(source.PictureId, "PictureId", source.LastName); provider.Custom1 = source.Custom1; provider.Custom2 = source.Custom2; provider.Custom3 = source.Custom3; }
public void can_set_AboutMe_null() { var provider = new Provider(); provider.SetAboutMe(null); Assert.IsNull(provider.AboutMe); }
public void can_set_AboutMe_blank() { var provider = new Provider(); provider.SetAboutMe(string.Empty); Assert.AreEqual(string.Empty, provider.AboutMe); }
public void can_set_AboutMe() { var value = Guid.NewGuid().ToString(); var provider = new Provider(); provider.SetAboutMe(value); Assert.AreEqual(value, provider.AboutMe); }