mirror of
https://github.com/inventree/InvenTree.git
synced 2026-10-10 04:06:14 +00:00
fix fronten tests failing (#12976)
This commit is contained in:
1 parent
575fbdc907
commit
800cbe0d30
3 files changed
+6
-1
No files matched your search
@@ -216,9 +216,10 @@ class CustomSocialAccountAdapter(RegistrationMixin, DefaultSocialAccountAdapter)
|
||||
return False
|
||||
|
||||
def authentication_error(
|
||||
self, request, provider_id, error=None, exception=None, extra_context=None
|
||||
self, request, provider, error=None, exception=None, extra_context=None
|
||||
):
|
||||
"""Callback method for authentication errors."""
|
||||
provider_id = getattr(provider, 'id', provider)
|
||||
if not error:
|
||||
error = request.GET.get('error', None)
|
||||
|
||||
|
||||
@@ -842,7 +842,9 @@ if DEBUG:
|
||||
'http://localhost',
|
||||
'http://*.localhost',
|
||||
'http://*localhost:8000',
|
||||
'http://localhost:4173',
|
||||
'http://*localhost:4173',
|
||||
'http://localhost:5173',
|
||||
'http://*localhost:5173',
|
||||
]:
|
||||
if origin not in CSRF_TRUSTED_ORIGINS:
|
||||
|
||||
@@ -178,6 +178,8 @@ class TestSocialAccountAdapter(TransactionTestCase):
|
||||
self.adapter.authentication_error(
|
||||
request, 'mock', error='denied', exception='User cancelled'
|
||||
)
|
||||
# new form
|
||||
self.adapter.authentication_error(request, {'id': 'mock'})
|
||||
|
||||
|
||||
class EmailSettingsContext:
|
||||
|
||||
Reference in new issue
Block a user