2024-02-11 04:38:05 +00:00
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_authorize_endpoint.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_authorize_endpoint.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_authorize_endpoint.py
|
|
|
|
@@ -7,7 +7,8 @@ try:
|
|
|
|
except ImportError:
|
|
|
|
from urlparse import parse_qs, urlsplit
|
|
|
|
import uuid
|
|
|
|
-from mock import patch, mock
|
2022-05-10 11:40:18 +00:00
|
|
|
+from unittest import mock
|
|
|
|
+from unittest.mock import patch
|
|
|
|
|
2024-02-11 04:38:05 +00:00
|
|
|
from django.contrib.auth.models import AnonymousUser
|
|
|
|
from django.core.management import call_command
|
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_end_session_endpoint.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_end_session_endpoint.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_end_session_endpoint.py
|
|
|
|
@@ -15,7 +15,7 @@ from oidc_provider.tests.app.utils impor
|
|
|
|
create_fake_client,
|
|
|
|
create_fake_user,
|
|
|
|
)
|
2022-05-10 11:40:18 +00:00
|
|
|
-import mock
|
|
|
|
+from unittest import mock
|
|
|
|
|
2024-02-11 04:38:05 +00:00
|
|
|
|
|
|
|
class EndSessionTestCase(TestCase):
|
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_introspection_endpoint.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_introspection_endpoint.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_introspection_endpoint.py
|
|
|
|
@@ -1,7 +1,8 @@
|
2022-05-10 11:40:18 +00:00
|
|
|
import time
|
2024-02-11 04:38:05 +00:00
|
|
|
import random
|
2022-05-10 11:40:18 +00:00
|
|
|
|
|
|
|
-from mock import patch
|
2024-02-11 04:38:05 +00:00
|
|
|
+from unittest import mock
|
2022-05-10 11:40:18 +00:00
|
|
|
+from unittest.mock import patch
|
|
|
|
try:
|
|
|
|
from urllib.parse import urlencode
|
2024-02-11 04:38:05 +00:00
|
|
|
except ImportError:
|
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_middleware.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_middleware.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_middleware.py
|
|
|
|
@@ -1,4 +1,4 @@
|
|
|
|
-import mock
|
2022-05-10 11:40:18 +00:00
|
|
|
+from unittest import mock
|
|
|
|
|
2024-02-11 04:38:05 +00:00
|
|
|
from django.urls import re_path
|
|
|
|
from django.test import TestCase, override_settings
|
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_token_endpoint.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_token_endpoint.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_token_endpoint.py
|
|
|
|
@@ -27,7 +27,7 @@ from django.views.decorators.http import
|
2022-05-10 11:40:18 +00:00
|
|
|
from jwkest.jwk import KEYS
|
|
|
|
from jwkest.jws import JWS
|
|
|
|
from jwkest.jwt import JWT
|
|
|
|
-from mock import patch
|
|
|
|
+from unittest.mock import patch
|
|
|
|
|
|
|
|
from oidc_provider.lib.endpoints.introspection import INTROSPECTION_SCOPE
|
|
|
|
from oidc_provider.lib.utils.oauth2 import protected_resource_view
|
2024-02-11 04:38:05 +00:00
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_utils.py
|
2022-05-10 11:40:18 +00:00
|
|
|
===================================================================
|
2024-02-11 04:38:05 +00:00
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_utils.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_utils.py
|
2022-05-10 11:40:18 +00:00
|
|
|
@@ -5,7 +5,7 @@ from hashlib import sha224
|
|
|
|
from django.http import HttpRequest
|
|
|
|
from django.test import TestCase, override_settings
|
|
|
|
from django.utils import timezone
|
|
|
|
-from mock import mock
|
|
|
|
+from unittest import mock
|
|
|
|
|
2024-02-11 04:38:05 +00:00
|
|
|
from oidc_provider.lib.utils.common import get_issuer, get_browser_state_or_default
|
|
|
|
from oidc_provider.lib.utils.token import create_token, create_id_token
|
|
|
|
Index: django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_provider_info_endpoint.py
|
|
|
|
===================================================================
|
|
|
|
--- django-oidc-provider-0.8.2.orig/oidc_provider/tests/cases/test_provider_info_endpoint.py
|
|
|
|
+++ django-oidc-provider-0.8.2/oidc_provider/tests/cases/test_provider_info_endpoint.py
|
|
|
|
@@ -1,4 +1,5 @@
|
|
|
|
-from mock import patch
|
|
|
|
+from unittest import mock
|
|
|
|
+from unittest.mock import patch
|
|
|
|
|
|
|
|
from django.core.cache import cache
|
|
|
|
try:
|