public void ReturnFalse_AtInitialCreation() { var intervalTriggeredMessage = new IntervalTriggeredMessage { DelayInMinutes = 1, Message = "Hello there!" }; intervalTriggeredMessage.Initialize(DateTime.Now); Assert.False(intervalTriggeredMessage.IsItYourTimeToDisplay(DateTime.Now)); }
public void ReturnTrue_GivenTimeEqualToDelayInMinutes() { var intervalTriggeredMessage = new IntervalTriggeredMessage { DelayInMinutes = 1, Message = "Hello there!" }; intervalTriggeredMessage.Initialize(DateTime.Now); Assert.True(intervalTriggeredMessage.IsItYourTimeToDisplay(DateTime.Now.AddMinutes(intervalTriggeredMessage.DelayInMinutes))); }