mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-25 11:01:12 +00:00
parent
bee9dafc9d
commit
6745a9a3f5
1 changed files with 8 additions and 0 deletions
|
@ -110,3 +110,11 @@ class StatusDisplayTags(TestCase):
|
||||||
)
|
)
|
||||||
result = status_display.get_published_date(date)
|
result = status_display.get_published_date(date)
|
||||||
self.assertEqual(result, "January 1")
|
self.assertEqual(result, "January 1")
|
||||||
|
|
||||||
|
with patch("django.utils.timezone.now") as timezone_mock:
|
||||||
|
timezone_mock.return_value = datetime.datetime(
|
||||||
|
# bookwyrm-social#3365: bug with exact month deltas
|
||||||
|
2022, 3, 1, 0, 0, tzinfo=datetime.timezone.utc
|
||||||
|
)
|
||||||
|
result = status_display.get_published_date(date)
|
||||||
|
self.assertEqual(result, "January 1")
|
||||||
|
|
Loading…
Reference in a new issue