From 7cbf3e93aa4c10ce7abd5f077a16ecdcfd89b77a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 3 Oct 2022 16:53:11 +0200 Subject: [PATCH] Skip test of scheduling cron on DST with dateutil dateutil does not compute the ambiguity of wall time correctly. issue11758 review418251003 --- trytond/tests/test_ir.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/trytond/tests/test_ir.py b/trytond/tests/test_ir.py index c32a9cfac3..0857c4e653 100644 --- a/trytond/tests/test_ir.py +++ b/trytond/tests/test_ir.py @@ -5,6 +5,11 @@ import unittest from decimal import Decimal from unittest.mock import ANY, Mock, patch +try: + import zoneinfo +except ImportError: + zoneinfo = None + from dateutil.relativedelta import relativedelta from trytond.config import config @@ -429,6 +434,7 @@ class IrCronTestCase(unittest.TestCase): cron.compute_next_call(datetime.datetime(2021, 12, 31, 5, 0)), datetime.datetime(2022, 1, 1, 6, 0)) + @unittest.skipIf(not zoneinfo, "dateutil does not compute correctly") @with_transaction() def test_scheduling_on_dst_change(self): "Test scheduling while the DST change occurs"