public SenderInfo Build() { SenderInfo result = new SenderInfo(); result.Email = email; result.FirstName = firstName; result.LastName = lastName; result.Company = company; result.Title = title; result.TimezoneId = timezoneId; return(result); }
public void ToAPIFromSDKSenderInfo() { OneSpanSign.Sdk.SenderInfo senderInfo = new OneSpanSign.Sdk.SenderInfo(); senderInfo.Email = EMAIL; senderInfo.FirstName = FIRST_NAME; senderInfo.LastName = LAST_NAME; senderInfo.Company = COMPANY; senderInfo.Title = TITLE; senderInfo.TimezoneId = TIMEZONE_ID; OneSpanSign.API.Sender sender = new SenderConverter(senderInfo).ToAPISender(); Assert.IsNotNull(sender); Assert.AreEqual(senderInfo.Email, sender.Email); Assert.AreEqual(senderInfo.FirstName, sender.FirstName); Assert.AreEqual(senderInfo.LastName, sender.LastName); Assert.AreEqual(senderInfo.Company, sender.Company); Assert.AreEqual(senderInfo.Title, sender.Title); Assert.AreEqual(senderInfo.TimezoneId, sender.TimezoneId); }
public void FromSDKNull() { OneSpanSign.Sdk.SenderInfo senderInfo = null; Assert.Throws <ArgumentNullException>(() => new SenderConverter(senderInfo)); }