magic-removal: Changed model unit tests to use new Model.objects.* syntax instead of models.*

git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@1595 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty 2005-12-11 22:10:02 +00:00
parent 69b82e1ca1
commit c1be782510
21 changed files with 186 additions and 186 deletions

View file

@ -132,7 +132,7 @@ class TestRunner:
# Run the API tests.
p = doctest.DocTestParser()
test_namespace = dict([(m._meta.module_name, getattr(mod, m._meta.module_name)) for m in mod._MODELS])
test_namespace = dict([(m._meta.object_name, getattr(mod, m._meta.module_name).Klass) for m in mod._MODELS])
dtest = p.get_doctest(mod.API_TESTS, test_namespace, model_name, None, None)
# Manually set verbose=False, because "-v" command-line parameter
# has side effects on doctest TestRunner class.