-
Notifications
You must be signed in to change notification settings - Fork 4
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
Restore RECAPTCHA_TESTING mechanism #5
Comments
Thanks for the report! I believe that Another idea would be to write a testing related client implementation that can be used in the fields accordingly, e.g something like class TestingCaptchaClient(ReCaptchaClient):
def verify(self, challenge, response, remote_ip):
return return RecaptchaResponse(is_valid=True, error_code=None) Not sure yet what feels right, I'll look into it a bit more later this or next week. |
Thank you! |
How would you change client in test then? Should there be settings variable for that? |
Hallo!
To make testing easier testing mechanism from django-recaptcha could be restored:
settings:
RECAPTCHA_TESTING = True
form data:
data['g-recaptcha-response'] = 'PASSED'
Currently it is necessary to mock verifying function
nobot.client.HumanCaptchaClient.verify
The text was updated successfully, but these errors were encountered: