def test_reset(self, mock_pr, mock_reverse): mock_request = mock.MagicMock() mock_reverse.return_value = 'accounts:login' mock_pr.return_value = True ret = reset(mock_request) self.assertTrue(ret) mock_pr.assert_called_once_with(mock_request, template_name='tethys_portal/accounts/password_reset/reset_request.html', email_template_name='tethys_portal/accounts/password_reset/reset_email.html', subject_template_name='tethys_portal/accounts/password_reset/reset_subject.txt', post_reset_redirect='accounts:login')
def test_reset(self, mock_pr, mock_reverse): mock_request = mock.MagicMock() mock_reverse.return_value = 'accounts:login' mock_pr.return_value = True ret = reset(mock_request) self.assertTrue(ret) mock_pr.assert_called_once_with( mock_request, template_name= 'tethys_portal/accounts/password_reset/reset_request.html', email_template_name= 'tethys_portal/accounts/password_reset/reset_email.html', subject_template_name= 'tethys_portal/accounts/password_reset/reset_subject.txt', success_url='accounts:login')