Commit 95d7a3ce authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

accept default parameter in dummy gettext().

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@26119 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 2e174885
...@@ -76,9 +76,12 @@ class DummyMessageCatalog: ...@@ -76,9 +76,12 @@ class DummyMessageCatalog:
__allow_access_to_unprotected_subobjects__ = 1 __allow_access_to_unprotected_subobjects__ = 1
def __init__(self): def __init__(self):
self._translated = [] self._translated = []
def gettext(self, word, *args, **kw): def gettext(self, word, lang=None, add=1, default=None, **kw):
self._translated.append(word) self._translated.append(word)
if default is None:
return word return word
else:
return default
class DummyLocalizer: class DummyLocalizer:
"""A replacement for stock cookie - based localizer. """A replacement for stock cookie - based localizer.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment