인증 메커니즘으로 django-social-auth를 사용하고 로그인 한 사용자로 내 앱을 테스트해야합니다. 나는 노력하고있어 :django-social-auth : 단위 테스트 클라이언트에서 로그인
from django.test import Client
c = Client()
c.login(username='[email protected]", password='myfacebookpassword')
브라우저를 사용하여 로그인하려는 사용자가 로그인에 성공했습니다. 앱에서 이미 사용자의 데이터에 액세스 할 수 있습니다.
인증 메커니즘으로 django-social-auth를 사용할 때 어떤 방법으로 unittest에서 로그인 할 수 있습니까?
감사
최근 Social Auth는 이러한 일을 쉽게 테스트 할 수있는 방법을 통합했습니다. http://django-social-auth.readthedocs.org/en/master/testing_tools.html을 살펴보십시오. – Nezo