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
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions odoo/addons/base/tests/test_tz.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import datetime
from freezegun import freeze_time
import logging
import pytz
from unittest.mock import patch
Expand Down Expand Up @@ -55,6 +56,7 @@ def test_cannot_set_deprecated_timezone(self):
with self.assertRaises(ValueError):
self.env.user.tz = "US/Eastern"

@freeze_time('2024-11-01')
def test_partner_with_old_tz(self):
# this test makes sence after ubuntu noble without tzdata-legacy installed
partner = self.env['res.partner'].create({'name': 'test', 'tz': 'UTC'})
Expand Down