# Path: rest_social_auth/views.py
# REDIRECT_URI = getattr(settings, 'REST_SOCIAL_OAUTH_REDIRECT_URI', '/')
# DOMAIN_FROM_ORIGIN = getattr(settings, 'REST_SOCIAL_DOMAIN_FROM_ORIGIN', True)
# LOG_AUTH_EXCEPTIONS = getattr(settings, 'REST_SOCIAL_LOG_AUTH_EXCEPTIONS', True)
# STRATEGY = getattr(settings, setting_name('STRATEGY'), 'rest_social_auth.strategy.DRFStrategy')
# def load_strategy(request=None):
# def decorate_request(request, backend):
#     def oauth_v1(self):
#     def get_serializer_class_in(self):
#     def get_serializer_in(self, *args, **kwargs):
#     def get_serializer_in_data(self):
#     def post(self, request, *args, **kwargs):
#     def get_object(self):
#     def save_token_param_in_session(self):
#     def do_login(self, backend, user):
#     def set_input_data(self, request, auth_data):
#     def get_redirect_uri(self, manual_redirect_uri):
#     def get_provider_name(self, input_data):
#     def respond_error(self, error):
#     def log_exception(self, error):
#     def do_login(self, backend, user):
#     def post(self, request, *args, **kwargs):
#     def get_authenticators(self):
#     def get_authenticators(self):
# class BaseSocialAuthView(GenericAPIView):
# class SocialSessionAuthView(BaseSocialAuthView):
# class SocialTokenOnlyAuthView(BaseSocialAuthView):
# class SocialTokenUserAuthView(BaseSocialAuthView):
# class KnoxAuthMixin(object):
# class SocialKnoxOnlyAuthView(KnoxAuthMixin, BaseSocialAuthView):
# class SocialKnoxUserAuthView(KnoxAuthMixin, BaseSocialAuthView):
# class SimpleJWTAuthMixin(object):
# class SocialJWTPairOnlyAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTPairUserAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTSlidingOnlyAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTSlidingUserAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):


import json
from httpretty import HTTPretty
from social_core.backends.utils import load_backends
from social_core.tests.backends.test_facebook import FacebookOAuth2Test
from social_core.tests.backends.test_twitter import TwitterOAuth1Test
from social_core.utils import module_member
from rest_social_auth import views




# don't run third party tests
for attr in (attr for attr in dir(FacebookOAuth2Test) if attr.startswith('test_')):
    delattr(FacebookOAuth2Test, attr)
for attr in (attr for attr in dir(TwitterOAuth1Test) if attr.startswith('test_')):
    delattr(TwitterOAuth1Test, attr)


class RestSocialMixin(object):
    def setUp(self):
        HTTPretty.enable()
        Backend = module_member(self.backend_path)

# Path: rest_social_auth/views.py
# REDIRECT_URI = getattr(settings, 'REST_SOCIAL_OAUTH_REDIRECT_URI', '/')
# DOMAIN_FROM_ORIGIN = getattr(settings, 'REST_SOCIAL_DOMAIN_FROM_ORIGIN', True)
# LOG_AUTH_EXCEPTIONS = getattr(settings, 'REST_SOCIAL_LOG_AUTH_EXCEPTIONS', True)
# STRATEGY = getattr(settings, setting_name('STRATEGY'), 'rest_social_auth.strategy.DRFStrategy')
# def load_strategy(request=None):
# def decorate_request(request, backend):
#     def oauth_v1(self):
#     def get_serializer_class_in(self):
#     def get_serializer_in(self, *args, **kwargs):
#     def get_serializer_in_data(self):
#     def post(self, request, *args, **kwargs):
#     def get_object(self):
#     def save_token_param_in_session(self):
#     def do_login(self, backend, user):
#     def set_input_data(self, request, auth_data):
#     def get_redirect_uri(self, manual_redirect_uri):
#     def get_provider_name(self, input_data):
#     def respond_error(self, error):
#     def log_exception(self, error):
#     def do_login(self, backend, user):
#     def post(self, request, *args, **kwargs):
#     def get_authenticators(self):
#     def get_authenticators(self):
# class BaseSocialAuthView(GenericAPIView):
# class SocialSessionAuthView(BaseSocialAuthView):
# class SocialTokenOnlyAuthView(BaseSocialAuthView):
# class SocialTokenUserAuthView(BaseSocialAuthView):
# class KnoxAuthMixin(object):
# class SocialKnoxOnlyAuthView(KnoxAuthMixin, BaseSocialAuthView):
# class SocialKnoxUserAuthView(KnoxAuthMixin, BaseSocialAuthView):
# class SimpleJWTAuthMixin(object):
# class SocialJWTPairOnlyAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTPairUserAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTSlidingOnlyAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):
# class SocialJWTSlidingUserAuthView(SimpleJWTAuthMixin, BaseSocialAuthView):


# Path: tests/base.py
import json
from httpretty import HTTPretty
from social_core.backends.utils import load_backends
from social_core.tests.backends.test_facebook import FacebookOAuth2Test
from social_core.tests.backends.test_twitter import TwitterOAuth1Test
from social_core.utils import module_member
from rest_social_auth import views





# don't run third party tests
for attr in (attr for attr in dir(FacebookOAuth2Test) if attr.startswith('test_')):
    delattr(FacebookOAuth2Test, attr)
for attr in (attr for attr in dir(TwitterOAuth1Test) if attr.startswith('test_')):
    delattr(TwitterOAuth1Test, attr)


class RestSocialMixin(object):
    def setUp(self):
        HTTPretty.enable()
        Backend = module_member(self.backend_path)

        self.strategy = views.load_strategy()