-
-
Notifications
You must be signed in to change notification settings - Fork 18.6k
(TST) Replacing Timestamp.now () in tests. #44501
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
(TST) Replacing Timestamp.now () in tests. #44501
Conversation
Hello @Mikhaylov-yv! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found: There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2021-11-20 18:47:30 UTC |
pandas/conftest.py
Outdated
Fixture emits fixed Timestamp.now() | ||
""" | ||
return Timestamp( | ||
year=2021, month=1, day=1, hour=12, minute=0, second=0, microsecond=0 |
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.
Per my previous suggestion, please make these not zero. e.g. 4, 13, 22
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.
I fixed it
Does this cover all the non-intentional cases of |
Yes it covers all cases. Where I was in doubt left |
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.
Thanks LGTM. If you're interested in a follow up, you could add a CI check to ensure now
is only used in a certain file where now
should be explicitly tested.
@mroeschke Oh sure. But I don’t understand how to do it. |
No problem can you merge master one more time @Mikhaylov-yv ? |
@mroeschke yes of course. |
Thanks @Mikhaylov-yv. CI failures unrelated |
Replacing Timestamp.now() in tests.
Left Timestamp.now () in the following tests: