Refs #23919 -- Removed unneeded force_str calls

This commit is contained in:
Claude Paroz 2017-01-11 23:17:25 +01:00
parent bf1c957027
commit dc8834cad4
44 changed files with 100 additions and 167 deletions

View file

@ -22,7 +22,6 @@ from django.test import (
RequestFactory, SimpleTestCase, ignore_warnings, override_settings,
)
from django.utils.deprecation import RemovedInDjango21Warning
from django.utils.encoding import force_str
int2byte = struct.Struct(">B").pack
@ -350,7 +349,7 @@ class CommonMiddlewareTest(SimpleTestCase):
def test_non_ascii_query_string_does_not_crash(self):
"""Regression test for #15152"""
request = self.rf.get('/slash')
request.META['QUERY_STRING'] = force_str('drink=café')
request.META['QUERY_STRING'] = 'drink=café'
r = CommonMiddleware().process_request(request)
self.assertEqual(r.status_code, 301)