Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fixes #98 Start Time of Day is not set correctly in DailyTimeInterval…

…TriggerPersistenceDelegate.GetTriggerProperties
  • Loading branch information...
commit f5df0ae1865230ce446cf0bde3b39e8a2a72f561 1 parent 3c0a50c
@lahma lahma authored
View
16 src/Quartz.Tests.Integration/Impl/SmokeTestPerformer.cs
@@ -154,6 +154,22 @@ public void Test(IScheduler scheduler, bool clearJobs, bool scheduleJobs)
// GitHub issue #92
scheduler.GetTrigger(nt2.Key);
+ // GitHub issue #98
+ nt2.StartTimeOfDay = new TimeOfDay(1, 2, 3);
+ nt2.EndTimeOfDay = new TimeOfDay(2, 3, 4);
+
+ scheduler.UnscheduleJob(nt2.Key);
+ scheduler.ScheduleJob(nt2);
+
+ var triggerFromDb = (IDailyTimeIntervalTrigger) scheduler.GetTrigger(nt2.Key);
+ Assert.That(triggerFromDb.StartTimeOfDay.Hour, Is.EqualTo(1));
+ Assert.That(triggerFromDb.StartTimeOfDay.Minute, Is.EqualTo(2));
+ Assert.That(triggerFromDb.StartTimeOfDay.Second, Is.EqualTo(3));
+
+ Assert.That(triggerFromDb.EndTimeOfDay.Hour, Is.EqualTo(2));
+ Assert.That(triggerFromDb.EndTimeOfDay.Minute, Is.EqualTo(3));
+ Assert.That(triggerFromDb.EndTimeOfDay.Second, Is.EqualTo(4));
+
job.RequestsRecovery = (true);
CalendarIntervalTriggerImpl intervalTrigger = new CalendarIntervalTriggerImpl(
"calint_trig_" + count,
View
2  src/Quartz/Impl/AdoJobStore/DailyTimeIntervalTriggerPersistenceDelegate.cs
@@ -72,9 +72,9 @@ protected override SimplePropertiesTriggerProperties GetTriggerProperties(IOpera
TimeOfDay startTimeOfDay = dailyTrigger.StartTimeOfDay;
if (startTimeOfDay != null)
{
+ timeOfDayBuffer.Append(startTimeOfDay.Hour).Append(",");
timeOfDayBuffer.Append(startTimeOfDay.Minute).Append(",");
timeOfDayBuffer.Append(startTimeOfDay.Second).Append(",");
- timeOfDayBuffer.Append(startTimeOfDay.Hour).Append(",");
}
else
{
Please sign in to comment.
Something went wrong with that request. Please try again.