Permalink
Browse files

admindocs locale fix

  • Loading branch information...
1 parent 0d79f50 commit 1865cef77c96af04e7a7457a5dc048842d860e5c @gugu gugu committed Sep 24, 2012
Showing with 4 additions and 3 deletions.
  1. +4 −3 django/contrib/admindocs/tests/__init__.py
@@ -1,6 +1,7 @@
from django.contrib.admindocs import views
from django.db.models import fields as builtin_fields
from django.utils import unittest
+from django.utils.translation import ugettext as _
import fields
@@ -17,15 +18,15 @@ def test_field_name(self):
def test_builtin_fields(self):
self.assertEqual(
views.get_readable_field_data_type(builtin_fields.BooleanField()),
- u'Boolean (Either True or False)'
+ _(u'Boolean (Either True or False)')
)
def test_custom_fields(self):
self.assertEqual(
views.get_readable_field_data_type(fields.CustomField()),
- u'A custom field type'
+ _(u'A custom field type')
)
self.assertEqual(
views.get_readable_field_data_type(fields.DescriptionLackingField()),
- u'Field of type: DescriptionLackingField'
+ _(u'Field of type: %(field_type)s') % {'field_type': 'DescriptionLackingField'}
)

0 comments on commit 1865cef

Please sign in to comment.