New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add cron expression assertion, Related to #3212 #3220
base: 3.x
Are you sure you want to change the base?
feat: Add cron expression assertion, Related to #3212 #3220
Conversation
It contains following apis: CronExpression cronExpression = new CronExpression("* * * * * *"); assertThat(cronExpression).isValid(); assertThat(cronExpression).containsExactlySeconds(...); assertThat(cronExpression).containsExactlyMinutes(...); assertThat(cronExpression).containsExactlyHours(...); assertThat(cronExpression).containsExactlyDayOfMonth(...); assertThat(cronExpression).containsExactlyMonth(...); assertThat(cronExpression).containsExactlyDayOfWeek(...); assertThat(cronExpression).containsExactlyYear(...);
Thanks, @neilwangweili! We'll review it shortly. Two initial thoughts:
WDYT? |
* CronExpression contains a cronable string that to set up a scheduled task. | ||
* @author Neil Wang | ||
*/ | ||
public class CronExpression { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Related to my comment, having this new type in the internal package and exposing it as part of the public API like in assertThat(CronExpression)
will cause trouble in module-path and OSGi based applications.
Okay, I'll look into it and do what you want. I don't have time this week so I'll do it next week. |
No worries, take your time of course, and let's also wait for some thoughts from @joel-costigliola. |
It contains following apis:
Check List:
Following the contributing guidelines will make it easier for us to review and accept your PR.