-
Notifications
You must be signed in to change notification settings - Fork 0
fix: tests: cron job tests #415
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
Conversation
|
sick work @Jo-Chris ! does that mean it is ready now? |
| ); | ||
| /** @DEV Edge case: if a user has never been reminded he is always in the 24 hrs bucket */ | ||
| if (!user.lastDateModeReminderSent) { | ||
| return TimeSpan.ONE_DAY; |
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.
Q: Do we also have test cases for users that:
- Have been reminded e.g. 2 months ago and now are in ghost mode? Meaning they should be in 24h bucket again
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.
This Edge case above is only if something is in ghost mode for 2 months and has never been reminded (for whatever reason). Checking the other case you mentioned, good call!
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.
Q: Do we also have test cases for users that:
- Have been reminded e.g. 2 months ago and now are in ghost mode? Meaning they should be in 24h bucket again
Well, they shouldn't (currently) - because we do not have a set-back logic. If you've been reminded the last time 2 months ago, that would mean you have received all the 3 notifications back then (from one day to 14 days off) and then the algorithm will not consider you, as you probably removed the app - somewhat (max 3 notifications).
So we'd need to reset the lastDateModeReminderSent to re-start that cycle.
wsdt
left a comment
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.
|
Commit 9cebdd0 restarts the cycle without having to reset the Will add 1-2 more tests after lunch, but very confident now. |
nice!! sick work Chris. pls let me know once ready to deploy. |
Bugfix Changelist:
Test Changelist: