summaryrefslogtreecommitdiff
path: root/tests/regressiontests/admin_widgets/tests.py
diff options
context:
space:
mode:
authorRussell Keith-Magee <russell@keith-magee.com>2009-07-23 14:31:33 +0000
committerRussell Keith-Magee <russell@keith-magee.com>2009-07-23 14:31:33 +0000
commit53d16b1175682f1ff97358b67190e4c935372b26 (patch)
treeffdc71bbea53b9d0a73882611ef65a1ff84e5fc3 /tests/regressiontests/admin_widgets/tests.py
parenta135608d910d0ec2ed03651908a454aa1ba34b9a (diff)
Fixed #11532 -- Corrected the link used for edit_inline foreign keys in admin when the admin is deployed using the old style admin.root approach. Thanks to JP for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@11314 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests/regressiontests/admin_widgets/tests.py')
-rw-r--r--tests/regressiontests/admin_widgets/tests.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/regressiontests/admin_widgets/tests.py b/tests/regressiontests/admin_widgets/tests.py
index 55088ca1fe..85651542bb 100644
--- a/tests/regressiontests/admin_widgets/tests.py
+++ b/tests/regressiontests/admin_widgets/tests.py
@@ -115,6 +115,7 @@ class AdminFormfieldForDBFieldWithRequestTests(DjangoTestCase):
class AdminForeignKeyWidgetChangeList(DjangoTestCase):
fixtures = ["admin-widgets-users.xml"]
+ admin_root = '/widget_admin'
def setUp(self):
self.client.login(username="super", password="secret")
@@ -123,5 +124,9 @@ class AdminForeignKeyWidgetChangeList(DjangoTestCase):
self.client.logout()
def test_changelist_foreignkey(self):
- response = self.client.get('/widget_admin/admin_widgets/car/')
- self.failUnless('/widget_admin/auth/user/add/' in response.content)
+ response = self.client.get('%s/admin_widgets/car/' % self.admin_root)
+ self.failUnless('%s/auth/user/add/' % self.admin_root in response.content)
+
+class OldAdminForeignKeyWidgetChangeList(AdminForeignKeyWidgetChangeList):
+ urls = 'regressiontests.admin_widgets.urls2'
+ admin_root = '/deep/down/admin'