def METHOD_NAME(client):
    # Validating a validated token should update the token attribute
    user = f.UserFactory.create()
    application = f.ApplicationFactory(next_url="http://next.url")
    token = f.ApplicationTokenFactory(
        auth_code="test-auth-code",
        state="test-state",
        application=application,
        token="existing-token")
    url = reverse("application-tokens-validate")
    client.login(user)
    data = {
        "application": token.application.id,
        "auth_code": "test-auth-code",
        "state": "test-state"
    }
    response = client.json.post(url, json.dumps(data))
    assert response.status_code == 200
    token = models.ApplicationToken.objects.get(id=token.id)
    assert token.token == "existing-token"