zope.i18n 5.1__py3-none-any.whl → 5.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- zope/i18n/format.py +1 -1
- zope/i18n/testmessagecatalog.py +2 -2
- zope/i18n/tests/test_formats.py +603 -714
- zope/i18n/tests/test_translationdomain.py +11 -4
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/METADATA +14 -3
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/RECORD +11 -11
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/WHEEL +1 -1
- /zope.i18n-5.1-py3.11-nspkg.pth → /zope.i18n-5.2-py3.11-nspkg.pth +0 -0
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/LICENSE.txt +0 -0
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/namespace_packages.txt +0 -0
- {zope.i18n-5.1.dist-info → zope.i18n-5.2.dist-info}/top_level.txt +0 -0
zope/i18n/format.py
CHANGED
@@ -612,7 +612,7 @@ def buildDateTimeParseInfo(calendar, pattern):
|
|
612
612
|
|
613
613
|
# am/pm marker (Text)
|
614
614
|
for entry in _findFormattingCharacterInPattern('a', pattern):
|
615
|
-
info[entry] =
|
615
|
+
info[entry] = fr'({calendar.am}|{calendar.pm})'
|
616
616
|
|
617
617
|
# era designator (Text)
|
618
618
|
# TODO: works for gregorian only right now
|
zope/i18n/testmessagecatalog.py
CHANGED
@@ -30,11 +30,11 @@ class TestMessageCatalog:
|
|
30
30
|
def queryMessage(self, msgid, default=None):
|
31
31
|
default = getattr(msgid, 'default', default)
|
32
32
|
if default is not None and default != msgid:
|
33
|
-
msg = "{} ({})"
|
33
|
+
msg = f"{msgid} ({default})"
|
34
34
|
else:
|
35
35
|
msg = msgid
|
36
36
|
|
37
|
-
return "[[{}][{}]]"
|
37
|
+
return f"[[{self.domain}][{msg}]]"
|
38
38
|
|
39
39
|
getMessage = queryMessage
|
40
40
|
|