#20432 closed Bug (fixed)
GroupAdminTest.test_group_permission_performance fail on full test suite run
Reported by: | otherjacob | Owned by: | |
---|---|---|---|
Component: | contrib.admin | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
the test passes when running all the admin_views tests in isolation, but fails when running with test suite.
Final pass of running the test against --bisect produces this:
======================================================================
FAIL: test_group_permission_performance (admin_views.tests.GroupAdminTest)
Traceback (most recent call last):
File "/Users/jacob/git/django/tests/admin_views/tests.py", line 3660, in test_group_permission_performance
self.assertEqual(response.status_code, 200)
File "/Users/jacob/git/django/django/test/testcases.py", line 181, in exit
executed, self.num
AssertionError: 7 queries executed, 8 expected
Ran 190 tests in 6.069s
FAILED (failures=1, skipped=2)
Destroying test database for alias 'default'...
Destroying test database for alias 'other'...
* Problem found in second half. Bisecting again...
* Source of error: django.contrib.auth
Change History (3)
comment:1 by , 12 years ago
comment:2 by , 12 years ago
Owner: | set to |
---|---|
Resolution: | → fixed |
Status: | new → closed |
The missing query is
ContentTypeManager caches get_for_model() queries. Another test caches the Group content type.