def METHOD_NAME(client, user):
    reset_req_url = reverse('account_reset_password')
    response = client.get(reset_req_url)
    assert response.status_code == 200
    response = client.post(reset_req_url, {'email': user.email})
    assert response.status_code == 302
    assert len(mail.outbox) == 1
    assert mail.outbox[0].to == [user.email]
    reset_url = re.search(
        r'(http://testserver/.*/)', str(mail.outbox[0].body)
    ).group(0)
    response = client.get(reset_url)
    assert response.status_code == 302
    reset_form_url = response.url
    response = client.get(reset_form_url)
    assert response.status_code == 200
    response = client.post(reset_form_url, {
        'password1': 'password1',
        'password2': 'password1',
    })
    assert response.status_code == 302
    assert response.url == '/'
    assert user.password != User.objects.get(username=user.username).password