private void validateEntity(RequestStatusNotificationView expected, RequestStatusNotificationData actual) { Assert.IsNotNull(expected); Assert.IsNotNull(actual); Assert.AreEqual(expected.ID, actual.ID); Assert.AreEqual(expected.Message, actual.Message); Assert.AreEqual(expected.SenderAccountId, actual.SenderId); Assert.AreEqual(expected.ReceiverAccountId, actual.ReceiverId); Assert.AreEqual(expected.IsSeen, actual.IsSeen); Assert.AreEqual(expected.Status, actual.Status); validateDates(expected.ValidFrom, actual.ValidFrom); validateDates(expected.ValidTo, actual.ValidTo); }
public static RequestStatusNotification CreateRequestStatusNotification(string id, string senderId, string receiverId, decimal?amount, TransactionStatus status = TransactionStatus.Pending, bool?isSeen = false, DateTime?validFrom = null, DateTime?validTo = null) { var r = new RequestStatusNotificationData { ID = id, ReceiverId = receiverId, SenderId = senderId, Amount = amount, Status = status, IsSeen = isSeen, ValidFrom = validFrom ?? DateTime.MinValue, ValidTo = validTo ?? DateTime.MaxValue }; return(new RequestStatusNotification(r)); }
private static RequestStatusNotification create(RequestStatusNotificationData data) { return(new RequestStatusNotification(data)); }