Skip to content

Commit

Permalink
Relative redirects now allowed
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiask committed Jan 8, 2016
1 parent 6085815 commit e26642d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions tests/testapp/tests/test_forms.py
Expand Up @@ -112,10 +112,9 @@ def test_searchform(self):
)

# Invalid query
self.assertRedirects(
self.client.get(list_url + '?created__year=abc'),
list_url + '?clear=1',
)
response = self.client.get(list_url + '?created__year=abc')
self.assertEqual(response.status_code, 302)
self.assertTrue(response['location'].endswith('?clear=1'))

# Mixed quick (only inactive) and form field (only active)
# Form field takes precedence
Expand Down

0 comments on commit e26642d

Please sign in to comment.