You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe there is an issue with generating the textual description for CRON expressions that contains hour-range definiton - according to the tutorial and the documentation, the hour-range is inclusive, meaning that if we put an hour definition as 10-14, the cron will also run in 14 hour (or 2PM). However, the textual description generated says between 10:00 AM and 1:00 PM, which is not true and is actually confusing.
Attached please find the failing test case:
/** * From QUARTZ tutorial (http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/tutorial-lesson-06.html): * CronTrigger Example 3 - an expression to create a trigger that fires at 10:30, 11:30, 12:30, and 13:30, on every Wednesday and Friday. * * Expected output (including 1PM): * At 30 minutes past the hour, between 10:00 AM and 2:00 PM, only on Wednesday and Friday * * Actual output: * At 30 minutes past the hour, between 10:00 AM and 1:00 PM, only on Wednesday and Friday * @throws Exception */@TestpublicvoidshouldMatchQuartzCronTutorial() throwsException {
Assert.assertEquals("At 30 minutes past the hour, between 10:00 AM and 2:00 PM, only on Wednesday and Friday", CronExpressionDescriptor.getDescription("0 30 10-13 ? * WED,FRI"));
}
The text was updated successfully, but these errors were encountered:
ok, I've looked through the code and I see it's not going to be easy to change the code to get the expected results.. Maybe instead of using "between X and Y", something like "X through Y" would be better?
So the expected output would be: At 30 minutes past the hour, 10:00 AM through 1:00 PM, only on Wednesday and Friday
I believe there is an issue with generating the textual description for CRON expressions that contains hour-range definiton - according to the tutorial and the documentation, the hour-range is inclusive, meaning that if we put an hour definition as 10-14, the cron will also run in 14 hour (or 2PM). However, the textual description generated says between 10:00 AM and 1:00 PM, which is not true and is actually confusing.
Attached please find the failing test case:
The text was updated successfully, but these errors were encountered: