summaryrefslogtreecommitdiff
path: root/tests/test_util_i18n.py
diff options
context:
space:
mode:
authorTakeshi KOMIYA <i.tkomiya@gmail.com>2021-01-13 00:39:13 +0900
committerTakeshi KOMIYA <i.tkomiya@gmail.com>2021-01-13 00:50:01 +0900
commit8ff8b5532cb55913d2076b7a7514b1cb83cae40c (patch)
tree9d49b226991cecadc63316c4dd393adcd93d4e3f /tests/test_util_i18n.py
parentd5559e1ba2d6ea5648a57301067a7461c268460e (diff)
downloadsphinx-git-8ff8b5532cb55913d2076b7a7514b1cb83cae40c.tar.gz
Fix #8683: html_last_updated_fmt generates wrong time zone for %Z
sphinx.util.i18n:format_date() converts '%Z' to full name of time zone unexpectedly. It should be converted to short name.
Diffstat (limited to 'tests/test_util_i18n.py')
-rw-r--r--tests/test_util_i18n.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/test_util_i18n.py b/tests/test_util_i18n.py
index d6f631175..180350e86 100644
--- a/tests/test_util_i18n.py
+++ b/tests/test_util_i18n.py
@@ -88,6 +88,8 @@ def test_format_date():
assert i18n.format_date(format, date=date) == 'Feb 7, 2016'
# timezone
+ format = '%Z'
+ assert i18n.format_date(format, date=datet) == 'UTC'
format = '%z'
assert i18n.format_date(format, date=datet) == '+0000'