Skip to content

Commit

Permalink
TST: Add test for comma when years are more than 1000
Browse files Browse the repository at this point in the history
  • Loading branch information
carterbox committed Dec 13, 2021
1 parent d1faf1c commit 96b44e6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/test_time.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ def test_naturaldelta_nomonths(test_input, expected):
(dt.timedelta(days=65), "2 months"),
(dt.timedelta(days=9), "9 days"),
(dt.timedelta(days=365), "a year"),
(dt.timedelta(days=365 * 1_141), "1,141 years"),
("NaN", "NaN"),
],
)
Expand Down Expand Up @@ -446,6 +447,7 @@ def test_naturaltime_minimum_unit_explicit(minimum_unit, seconds, expected):
(3600 * 24 * 2, "seconds", "2 days"),
(3600 * 24 * 365, "seconds", "1 year"),
(3600 * 24 * 365 * 2, "seconds", "2 years"),
(3600 * 24 * 365 * 1_963, "seconds", "1,963 years"),
],
)
def test_precisedelta_one_unit_enough(val, min_unit, expected):
Expand Down

0 comments on commit 96b44e6

Please sign in to comment.