Skip to content

Commit f1b9ad3

Browse files
Alexey Izbyshevbenjaminp
Alexey Izbyshev
authored andcommitted
closes bpo-35171: Fix test_TimeRE_recreation_timezone failure on some systems. (GH-10347)
The test depended on '/usr/share/zoneinfo/posixrules' or equivalent because it set TZ without explicit DST transition rules. At least on OpenSUSE Tumbleweed that file is linked to '/etc/localtime', making the test fail with certain local timezones, such as 'Europe/Moscow' which doesn't have DST transitions since 2011.
1 parent f1d3efc commit f1b9ad3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/test/test_strptime.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -692,7 +692,7 @@ def test_TimeRE_recreation_locale(self):
692692
finally:
693693
locale.setlocale(locale.LC_TIME, locale_info)
694694

695-
@support.run_with_tz('STD-1DST')
695+
@support.run_with_tz('STD-1DST,M4.1.0,M10.1.0')
696696
def test_TimeRE_recreation_timezone(self):
697697
# The TimeRE instance should be recreated upon changing the timezone.
698698
oldtzname = time.tzname

0 commit comments

Comments
 (0)