We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 97c6831 commit 84c27a0Copy full SHA for 84c27a0
pytest_django/plugin.py
@@ -441,7 +441,11 @@ def _django_set_urlconf(request):
441
if marker:
442
skip_if_no_django()
443
import django.conf
444
- from django.core.urlresolvers import clear_url_caches, set_urlconf
+ try:
445
+ from django.urls import clear_url_caches, set_urlconf
446
+ except ImportError:
447
+ # Removed in Django 2.0
448
+ from django.core.urlresolvers import clear_url_caches, set_urlconf
449
450
validate_urls(marker)
451
original_urlconf = django.conf.settings.ROOT_URLCONF
0 commit comments