public void IsDayOff_ReturnsTrue_ForWeekend() { //Arrange HolidaysManager manager = new HolidaysManager(); DateTime checkedDate = new DateTime(2017, 5, 6, 11, 15, 0); //Act //Assert bool isDayOff = manager.IsDayOff(checkedDate); Assert.IsTrue(isDayOff); }
public void IsDayOff_ReturnsFalse_ForWorkingDay() { //Arrange HolidaysManager manager = new HolidaysManager(); DateTime checkedDate = new DateTime(2017, 5, 2, 11, 15, 0); //Act //Assert bool isDayOff = manager.IsDayOff(checkedDate); Assert.IsFalse(isDayOff); }
public void IsDayOff_ReturnsTrue_ForWeekDayHoliday() { //Arrange HolidaysManager manager = new HolidaysManager(); DateTime checkedDate = new DateTime(2017, 5, 2, 11, 15, 0); //Act manager.AddHoliday(checkedDate.Midnight()); //Assert bool isDayOff = manager.IsDayOff(checkedDate); Assert.IsTrue(isDayOff); }