Skip to content

Commit 3c6b939

Browse files
committed
add a regression test for noon and midnight
1 parent b0c8d6b commit 3c6b939

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/test_time.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,17 @@ def test_militarize_hours(self):
111111
23
112112
)
113113

114+
def regression_test_noon_midnight(self):
115+
116+
self.assertEqual(
117+
Time.from_string("12pm").get_as_military_time().get_hours(),
118+
12
119+
)
120+
self.assertEqual(
121+
Time.from_string("12am").get_as_military_time().get_hours(),
122+
0
123+
)
124+
114125
# def test_detect_pm(self):
115126
# input_strings = [
116127
# "pm",

0 commit comments

Comments
 (0)