diff options
Diffstat (limited to 'rest_framework/tests/utils.py')
| -rw-r--r-- | rest_framework/tests/utils.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/rest_framework/tests/utils.py b/rest_framework/tests/utils.py index 3906adb9..224c4f9d 100644 --- a/rest_framework/tests/utils.py +++ b/rest_framework/tests/utils.py @@ -1,6 +1,7 @@ +from __future__ import unicode_literals from django.test.client import RequestFactory, FakePayload from django.test.client import MULTIPART_CONTENT -from urlparse import urlparse +from rest_framework.compat import urlparse class RequestFactory(RequestFactory): @@ -14,7 +15,7 @@ class RequestFactory(RequestFactory): patch_data = self._encode_data(data, content_type) - parsed = urlparse(path) + parsed = urlparse.urlparse(path) r = { 'CONTENT_LENGTH': len(patch_data), 'CONTENT_TYPE': content_type, |
