Browse files

Fixed failing tests from [8352]. Thanks Alex Gaynor for the patch.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
brosner committed Aug 14, 2008
1 parent dd0e5fd commit 21029678078b8f69ff438ea9ed5a9a9359b05b2e
Showing with 3 additions and 2 deletions.
  1. +1 −1 django/contrib/admin/
  2. +2 −1 tests/regressiontests/modeladmin/
@@ -39,7 +39,7 @@ def _check_attr_existsw(label, field):
if not hasattr(cls, field):
if not hasattr(model, field):
- return opts.get_field(field)
+ opts.get_field(field)
except models.FieldDoesNotExist:
raise ImproperlyConfigured("%s.list_display[%d], %r is "
"not a callable or an attribute of %r or found in the model %r."
@@ -559,7 +559,8 @@ class and an AdminSite instance, so let's just go ahead and do that manually
>>> validate(ValidationTestModelAdmin, ValidationTestModel)
Traceback (most recent call last):
-ImproperlyConfigured: `ValidationTestModelAdmin.list_display[0]` refers to `non_existent_field` that is neither a field, method or property of model `ValidationTestModel`.
+ImproperlyConfigured: ValidationTestModelAdmin.list_display[0], 'non_existent_field' is not a callable or an attribute of 'ValidationTestModelAdmin' or found in the model 'ValidationTestModel'.
>>> class ValidationTestModelAdmin(ModelAdmin):
... list_display = ('users',)

0 comments on commit 2102967

Please sign in to comment.