Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed #290 -- Importing from django.core.urlresolvers is deprecated in favor of django.urls #291

Merged
merged 5 commits into from
Dec 21, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ Here is an example of these rules applied:

# second set of imports are Django imports with contrib in their own
# group.
from django.core.urlresolvers import reverse
from django.urls import reverse
from django.db import models
from django.utils import timezone
from django.utils.translation import ugettext_lazy as _
Expand Down
6 changes: 5 additions & 1 deletion pinax/stripe/middleware.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import django
from django.core.urlresolvers import resolve
from django.shortcuts import redirect

try:
from django.urls import resolve
except ImportError:
from django.core.urlresolvers import resolve

from .actions import customers, subscriptions
from .conf import settings

Expand Down
6 changes: 5 additions & 1 deletion pinax/stripe/tests/test_admin.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
import datetime

from django.contrib.auth import get_user_model
from django.core.urlresolvers import reverse
from django.test import Client, TestCase
from django.utils import timezone

try:
from django.urls import reverse
except ImportError:
from django.core.urlresolvers import reverse

from ..models import Customer, Invoice, Plan, Subscription


Expand Down
6 changes: 5 additions & 1 deletion pinax/stripe/tests/test_middleware.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
from django.core.urlresolvers import reverse
from django.test import TestCase
from django.utils import timezone

try:
from django.urls import reverse
except ImportError:
from django.core.urlresolvers import reverse

from django.contrib.auth import authenticate, login, logout, get_user_model

from mock import Mock
Expand Down
6 changes: 5 additions & 1 deletion pinax/stripe/tests/test_views.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
from django.core.urlresolvers import reverse
from django.test import TestCase
from django.utils import timezone

try:
from django.urls import reverse
except ImportError:
from django.core.urlresolvers import reverse

from django.contrib.auth import get_user_model

import stripe
Expand Down
6 changes: 5 additions & 1 deletion pinax/stripe/tests/test_webhooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,15 @@

import six

from django.core.urlresolvers import reverse
from django.dispatch import Signal
from django.test import TestCase
from django.test.client import Client

try:
from django.urls import reverse
except ImportError:
from django.core.urlresolvers import reverse

import stripe

from mock import patch
Expand Down