public static Func <bool> IsDateEquals(DateTime date1, DateTime date2, string message) { return(delegate() { if (!(date1.Date == date2.Date)) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsNull(object obj, string message) { return(delegate() { if (obj != null) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsEquals(int value1, int value2, string message) { return(delegate() { if (!(value1 == value2)) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsGuidNotEmpty(Guid guid, string message) { return(delegate() { if (Guid.Empty == guid) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsGuidNotNull(Guid guid, string message) { return(delegate() { if (guid == null) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> HasMinimumLength(string value, int minLength, string message) { return(delegate() { if (value.Length < minLength) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsLowerOrEquals(DateTime value1, DateTime value2, string message) { return(delegate() { if (!(value1 <= value2)) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsStringNotNullOrWhiteSpace(string value, string message) { return(delegate() { if (string.IsNullOrWhiteSpace(value)) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> IsGreaterThanOrEquals(decimal?value1, decimal value2, string message) { return(delegate() { if (!(value1 >= value2)) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static Func <bool> HasLengthEquals(string value, int length, string message) { return(delegate() { if (value?.Length != length) { DomainNotificationsFacade.AddNotification(message); return false; } return true; }); }
public static bool HasNotifications() { return(DomainNotificationsFacade.HasNotifications()); }
public AddAuthorCommandTest() { DomainNotificationsFacade.SetTestingEnvironment(); }
public BookLoanTests() { DomainNotificationsFacade.SetTestingEnvironment(); }
public AuthorTests() { DomainNotificationsFacade.SetTestingEnvironment(); }
public PersonTests() { DomainNotificationsFacade.SetTestingEnvironment(); }
public AddBookCommandTests() { DomainNotificationsFacade.SetTestingEnvironment(); }
public RequestLoanCommandTests() { DomainNotificationsFacade.SetTestingEnvironment(); }