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

[FIX] base: freeze time timezone test #53

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

Conversation

amh-mw
Copy link
Member

@amh-mw amh-mw commented Nov 4, 2024

Versions

  • 15.0+

Issue

test_partner_with_old_tz fails when ran after 2024-11-03.

Cause

It checks on a hardcoded UTC offset. A timezone's UTC offset changes along with DST, which is what happened for the 'US/Eastern' timezone on 2024-11-03.

Solution

Use freeze_time on the test, so it always runs with DST.

Description of the issue/feature this PR addresses:

Current behavior before PR:

Desired behavior after PR is merged:


I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

Versions
--------
- 15.0+

Issue
-----
`test_partner_with_old_tz` fails when ran after 2024-11-03.

Cause
-----
It checks on a hardcoded UTC offset. A timezone's UTC offset changes
along with DST, which is what happened for the 'US/Eastern' timezone on
2024-11-03.

Solution
--------
Use `freeze_time` on the test, so it always runs with DST.
@amh-mw amh-mw added the 15.0 label Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants