Skip to content
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

Add Task model tests #2039

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

danielgomezrico
Copy link
Contributor

@danielgomezrico danielgomezrico commented Oct 24, 2023

my Habitica User-ID: 6a5dcf62-46d7-41f6-b4a5-19b1bc8a3784

This PR will add unit tests to the Task model, I saw some issues related to reminders and dates and wanted to add tests to be sure that this logic is working as expected.

Related issues:

Are there any other cases that I should be covering here?

Can you add hacktoberfest-accepted label to this PR please?

@danielgomezrico danielgomezrico marked this pull request as ready for review October 24, 2023 20:19
@danielgomezrico
Copy link
Contributor Author

Tests are not passing but its related to main codebase, trying to fix them on #2045

@Hafizzle
Copy link
Contributor

Hey @danielgomezrico,

First off, big thanks for diving into Task model tests! It's really cool to see your initiative in adding unit tests, especially around reminders and dates. This is super important for keeping everything running smoothly.

I've gone through your tests, and they're a solid start – they cover the basic scenarios well. However, we're thinking it might be even better to add some more real-world complexity to these tests. For example:

How about testing how the isDueToday function behaves across different time zones?
Maybe throw in some scenarios for leap years or unusual date setups?
Testing the function with a variety of task types and configurations could also be really insightful.

These additions would really beef up the robustness of our tests and make sure we're covering as many user scenarios as possible.

Thanks again for your work :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants