Ticket #15067: 15067_test.diff

File 15067_test.diff, 835 bytes (added by jboutros, 14 years ago)

Test case for overflow condition. The supplied patch passes this test.

  • django/contrib/auth/tests/views.py

     
    104104        self.assertEquals(response.status_code, 200)
    105105        self.assert_("The password reset link was invalid" in response.content)
    106106
     107    def test_confirm_overflow_user(self):
     108        # Ensure that we get a 200 response for a base36 user id that overflows int
     109        response = self.client.get('/reset/zzzzzzzzzzzzz-1-1/')
     110        self.assertEquals(response.status_code, 200)
     111        self.assert_("The password reset link was invalid" in response.content)
     112
    107113    def test_confirm_invalid_post(self):
    108114        # Same as test_confirm_invalid, but trying
    109115        # to do a POST instead.
Back to Top