Skip to content

Commit

Permalink
Merge pull request #89 from da4089/master
Browse files Browse the repository at this point in the history
Fix timezone names in test suite
  • Loading branch information
da4089 authored Dec 19, 2024
2 parents 38defb3 + aab9e0d commit afeaef2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions tests/test_icalendar.py
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,8 @@ def test_issue50():


def test_includes_dst_offset():
tz = dateutil.tz.gettz('us/eastern')
tz = dateutil.tz.gettz('US/Eastern')
assert tz is not None

# Simple first
dt = datetime.datetime(2020, 1, 1)
Expand All @@ -519,9 +520,13 @@ def test_omits_dst_offset():
# Check dateutil, pytz, and zoneinfo (3.9+) tzinfo instances
timezones = []
if 'dateutil' in globals():
timezones.append(dateutil.tz.gettz('us/eastern'))
tz = dateutil.tz.gettz('US/Eastern')
assert tz is not None
timezones.append(tz)
if 'zoneinfo' in globals():
timezones.append(zoneinfo.ZoneInfo('us/eastern'))
tz = zoneinfo.ZoneInfo('US/Eastern')
assert tz is not None
timezones.append(tz)

for tz in timezones:
dt = datetime.datetime(2020, 1, 1)
Expand Down

0 comments on commit afeaef2

Please sign in to comment.