Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Corrected a test failure under Postgres caused by PK allocation. Than…

…ks to Alex for the report.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15147 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 39b3269fec788bebf900081d26b94eccad6d086b 1 parent c0dd2ba
@freakboy3742 freakboy3742 authored
Showing with 2 additions and 1 deletion.
  1. +2 −1  tests/regressiontests/generic_views/edit.py
View
3  tests/regressiontests/generic_views/edit.py
@@ -41,7 +41,8 @@ def test_create_with_object_url(self):
res = self.client.post('/edit/artists/create/',
{'name': 'Rene Magritte'})
self.assertEqual(res.status_code, 302)
- self.assertRedirects(res, 'http://testserver/detail/artist/1/')
+ artist = Artist.objects.get(name='Rene Magritte')
+ self.assertRedirects(res, 'http://testserver/detail/artist/%d/' % artist.pk)
self.assertQuerysetEqual(Artist.objects.all(), ['<Artist: Rene Magritte>'])
def test_create_with_redirect(self):
Please sign in to comment.
Something went wrong with that request. Please try again.