summaryrefslogtreecommitdiffstats
path: root/tests/test_ipalib/test_parameters.py
diff options
context:
space:
mode:
authorJohn Dennis <jdennis@redhat.com>2010-03-05 16:11:21 -0500
committerJason Gerard DeRose <jderose@redhat.com>2010-03-08 21:10:36 -0700
commitb75d06e18938015ad6eafe53e15aa2d7a2f92f02 (patch)
tree856e8b5457e91cb1a9bd628ef8ce82c99dc79657 /tests/test_ipalib/test_parameters.py
parentb9df4f7f29a638d3646c5ff1ffc33c00f7d715c6 (diff)
downloadfreeipa-b75d06e18938015ad6eafe53e15aa2d7a2f92f02.tar.gz
freeipa-b75d06e18938015ad6eafe53e15aa2d7a2f92f02.tar.xz
freeipa-b75d06e18938015ad6eafe53e15aa2d7a2f92f02.zip
localize doc strings
A number of doc strings were not localized, wrap them in _(). Some messages were not localized, wrap them in _() Fix a couple of failing tests: The method name in RPC should not be unicode. The doc attribute must use the .msg attribute for comparison. Also clean up imports of _() The import should come from ipalib or ipalib.text, not ugettext from request.
Diffstat (limited to 'tests/test_ipalib/test_parameters.py')
-rw-r--r--tests/test_ipalib/test_parameters.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/test_ipalib/test_parameters.py b/tests/test_ipalib/test_parameters.py
index b5a01fdec..038941b80 100644
--- a/tests/test_ipalib/test_parameters.py
+++ b/tests/test_ipalib/test_parameters.py
@@ -31,7 +31,7 @@ from tests.data import binary_bytes, utf8_bytes, unicode_str
from ipalib import parameters, request, errors, config
from ipalib.constants import TYPE_ERROR, CALLABLE_ERROR, NULLS
from ipalib.errors import ValidationError
-
+from ipalib import _
class test_DefaultFrom(ClassChecker):
"""
@@ -192,9 +192,9 @@ class test_Param(ClassChecker):
assert o.flags == frozenset()
# Test that doc defaults from label:
- o = self.cls('my_param', doc='Hello world')
+ o = self.cls('my_param', doc=_('Hello world'))
assert o.label.msg == 'my_param'
- assert o.doc == 'Hello world'
+ assert o.doc.msg == 'Hello world'
o = self.cls('my_param', label='My Param')
assert o.label == 'My Param'