1
0
mirror of https://github.com/django/django.git synced 2025-10-26 15:16:09 +00:00

[soc2009/multidb] Merged up to trunk r11756.

git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11758 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Alex Gaynor
2009-11-21 06:55:11 +00:00
parent 2bc7422b52
commit e9e73c4b68
198 changed files with 5793 additions and 1878 deletions

View File

@@ -885,8 +885,9 @@ class AdminViewListEditable(TestCase):
# 4 action inputs (3 regular checkboxes, 1 checkbox to select all)
# main form submit button = 1
# search field and search submit button = 2
# 6 + 2 + 1 + 2 = 11 inputs
self.failUnlessEqual(response.content.count("<input"), 15)
# CSRF field = 1
# 6 + 2 + 4 + 1 + 2 + 1 = 16 inputs
self.failUnlessEqual(response.content.count("<input"), 16)
# 1 select per object = 3 selects
self.failUnlessEqual(response.content.count("<select"), 4)
@@ -1140,6 +1141,16 @@ class AdminActionsTest(TestCase):
'<input type="checkbox" class="action-select"' not in response.content,
"Found an unexpected action toggle checkboxbox in response"
)
self.assert_('action-checkbox-column' not in response.content,
"Found unexpected action-checkbox-column class in response")
def test_action_column_class(self):
"Tests that the checkbox column class is present in the response"
response = self.client.get('/test_admin/admin/admin_views/subscriber/')
self.assertNotEquals(response.context["action_form"], None)
self.assert_('action-checkbox-column' in response.content,
"Expected an action-checkbox-column in response")
def test_multiple_actions_form(self):
"""