Skip to content

Commit d838236

Browse files
committed
init passing tests
1 parent 43c8345 commit d838236

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

Lib/test/datetimetester.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2207,6 +2207,13 @@ def test_strptime_D_format(self):
22072207
self.theclass.strptime(test_date, "%m/%d/%y")
22082208
)
22092209

2210+
def test_strptime_t_format(self):
2211+
test_date = "2026\t02\t16"
2212+
self.assertEqual(
2213+
self.theclass.strptime(test_date, "%Y%t%m%t%d"),
2214+
self.theclass.strptime(test_date, "%Y\t%m\t%d")
2215+
)
2216+
22102217

22112218
#############################################################################
22122219
# datetime tests

Lib/test/test_strptime.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -670,6 +670,13 @@ def test_strptime_D_format(self):
670670
time.strptime(test_date, "%m/%d/%y")
671671
)
672672

673+
def test_strptime_t_format(self):
674+
test_date = "2026\t02\t16"
675+
self.assertEqual(
676+
time.strptime(test_date, "%Y%t%m%t%d"),
677+
time.strptime(test_date, "%Y\t%m\t%d")
678+
)
679+
673680
class Strptime12AMPMTests(unittest.TestCase):
674681
"""Test a _strptime regression in '%I %p' at 12 noon (12 PM)"""
675682

Lib/test/test_time.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ def test_strptime(self):
359359
# raising an exception.
360360
tt = time.gmtime(self.t)
361361
for directive in ('a', 'A', 'b', 'B', 'c', 'd', 'D', 'F', 'H', 'I',
362-
'j', 'm', 'M', 'p', 'S', 'T',
362+
'j', 'm', 'M', 'p', 'S', 't', 'T',
363363
'U', 'w', 'W', 'x', 'X', 'y', 'Y', 'Z', '%'):
364364
format = '%' + directive
365365
if directive == 'd':

0 commit comments

Comments
 (0)