tests: don't check for invalid parameter decoding in python 3 (#35425)

This commit is contained in:
Frédéric Péters 2019-08-18 12:57:00 +02:00
parent 1681ec8672
commit e42143e009
1 changed files with 3 additions and 1 deletions

View File

@ -12,6 +12,7 @@ from django.contrib.auth.models import User, Group
from django.core.urlresolvers import reverse
from django.db import connection
from django.utils.http import quote
from django.utils import six
from django.utils.six.moves.urllib import parse as urlparse
from django.test import override_settings
from django.test.utils import CaptureQueriesContext
@ -86,7 +87,8 @@ def test_mellon_login(app):
assert urlparse.urlparse(resp.location).path == '/accounts/mellon/login/'
resp = app.get('/login/?next=whatever')
assert urlparse.urlparse(resp.location).query == 'next=whatever'
resp = app.get('/login/?next=%e0%40', status=400)
if six.PY2:
resp = app.get('/login/?next=%e0%40', status=400)
def test_page_contents_group_presence(app, normal_user):
group = Group(name='plop')