mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-25 00:33:58 -04:00
notify-api-861 show eastern time
This commit is contained in:
@@ -87,38 +87,38 @@ def test_format_number_in_pounds_as_currency(input_number, formatted_number):
|
||||
("time", "human_readable_datetime"),
|
||||
[
|
||||
# incoming in UTC, outgoing in "human formatted" UTC
|
||||
("2018-03-14 09:00", "14 March at 09:00 UTC"),
|
||||
("2018-03-14 19:00", "14 March at 19:00 UTC"),
|
||||
("2018-03-15 09:00", "15 March at 09:00 UTC"),
|
||||
("2018-03-15 19:00", "15 March at 19:00 UTC"),
|
||||
("2018-03-19 09:00", "19 March at 09:00 UTC"),
|
||||
("2018-03-19 19:00", "19 March at 19:00 UTC"),
|
||||
("2018-03-19 23:59", "19 March at 23:59 UTC"),
|
||||
("2018-03-14 09:00", "14 March at 05:00 US/Eastern"),
|
||||
("2018-03-14 19:00", "14 March at 15:00 US/Eastern"),
|
||||
("2018-03-15 09:00", "15 March at 05:00 US/Eastern"),
|
||||
("2018-03-15 19:00", "15 March at 15:00 US/Eastern"),
|
||||
("2018-03-19 09:00", "19 March at 05:00 US/Eastern"),
|
||||
("2018-03-19 19:00", "19 March at 15:00 US/Eastern"),
|
||||
("2018-03-19 23:59", "19 March at 19:59 US/Eastern"),
|
||||
(
|
||||
"2018-03-20 00:00",
|
||||
"19 March at 00:00 UTC",
|
||||
"2018-03-20 04:00",
|
||||
"19 March at 00:00 US/Eastern",
|
||||
), # we specifically refer to 00:00 as belonging to the day before.
|
||||
("2018-03-20 04:01", "yesterday at 04:01 UTC"),
|
||||
("2018-03-20 09:00", "yesterday at 09:00 UTC"),
|
||||
("2018-03-20 19:00", "yesterday at 19:00 UTC"),
|
||||
("2018-03-20 23:59", "yesterday at 23:59 UTC"),
|
||||
("2018-03-20 04:01", "yesterday at 00:01 US/Eastern"),
|
||||
("2018-03-20 09:00", "yesterday at 05:00 US/Eastern"),
|
||||
("2018-03-20 19:00", "yesterday at 15:00 US/Eastern"),
|
||||
("2018-03-20 23:59", "yesterday at 19:59 US/Eastern"),
|
||||
(
|
||||
"2018-03-21 00:00",
|
||||
"yesterday at 00:00 UTC",
|
||||
"2018-03-21 04:00",
|
||||
"yesterday at 00:00 US/Eastern",
|
||||
), # we specifically refer to 00:00 as belonging to the day before.
|
||||
("2018-03-21 04:01", "today at 04:01 UTC"),
|
||||
("2018-03-21 09:00", "today at 09:00 UTC"),
|
||||
("2018-03-21 12:00", "today at 12:00 UTC"),
|
||||
("2018-03-21 19:00", "today at 19:00 UTC"),
|
||||
("2018-03-21 23:59", "today at 23:59 UTC"),
|
||||
("2018-03-22 00:00", "today at 00:00 UTC"),
|
||||
("2018-03-22 04:01", "tomorrow at 04:01 UTC"),
|
||||
("2018-03-22 09:00", "tomorrow at 09:00 UTC"),
|
||||
("2018-03-22 19:00", "tomorrow at 19:00 UTC"),
|
||||
("2018-03-22 23:59", "tomorrow at 23:59 UTC"),
|
||||
("2018-03-23 04:01", "23 March at 04:01 UTC"),
|
||||
("2018-03-23 09:00", "23 March at 09:00 UTC"),
|
||||
("2018-03-23 19:00", "23 March at 19:00 UTC"),
|
||||
("2018-03-21 04:01", "today at 00:01 US/Eastern"),
|
||||
("2018-03-21 09:00", "today at 05:00 US/Eastern"),
|
||||
("2018-03-21 12:00", "today at 08:00 US/Eastern"),
|
||||
("2018-03-21 19:00", "today at 15:00 US/Eastern"),
|
||||
("2018-03-21 23:59", "today at 19:59 US/Eastern"),
|
||||
("2018-03-22 00:00", "today at 20:00 US/Eastern"),
|
||||
("2018-03-22 04:01", "tomorrow at 00:01 US/Eastern"),
|
||||
("2018-03-22 09:00", "tomorrow at 05:00 US/Eastern"),
|
||||
("2018-03-22 19:00", "tomorrow at 15:00 US/Eastern"),
|
||||
("2018-03-22 23:59", "tomorrow at 19:59 US/Eastern"),
|
||||
("2018-03-23 04:01", "23 March at 00:01 US/Eastern"),
|
||||
("2018-03-23 09:00", "23 March at 05:00 US/Eastern"),
|
||||
("2018-03-23 19:00", "23 March at 15:00 US/Eastern"),
|
||||
],
|
||||
)
|
||||
def test_format_datetime_relative(time, human_readable_datetime):
|
||||
|
||||
Reference in New Issue
Block a user