public static void GetCronExpressionFromSchedule_UnsupportedSchedule_Throws()
        {
            var schedule = new NullSchedule();
            var ex       = Assert.Throws <NotSupportedException>(() => ScheduleCronExpressionConverter.ToCronExpression(schedule));

            Assert.Equal("Unsupported Schedule: " + schedule.GetType().AssemblyQualifiedName, ex.Message);
        }
 public void GetCronExpressionFromSchedule_NullClone_Works()
 {
     var schedule = new NullSchedule();
     var cloned = schedule.Clone();
     var clonedTyped = Assert.IsType<NullSchedule>(cloned);
     Assert.Equal(schedule.GetType(), clonedTyped.GetType());
     Assert.NotSame(schedule, clonedTyped);
 }
 public void GetCronExpressionFromSchedule_UnsupportedSchedule_Throws()
 {
     var schedule = new NullSchedule();
     var ex = Assert.Throws<NotSupportedException>(() => ScheduleCronExpressionConverter.ToCronExpression(schedule));
     Assert.Equal("Unsupported Schedule: " + schedule.GetType().AssemblyQualifiedName, ex.Message);
 }