title: Testing csrf token in django
body: <p>I'm looking to test if csrf tokens are working in my django site. The issue is that csrf_token returns a token value rather that the custom value of 'csrftoken'. Is there a way to set the value of the csrf for testing? This is the code that I am working with:</p>
  
  <pre><code>token = 'csrftoken'
  client = Client(enforce_csrf_checks=True)
  client.login(username='user', password='pass')
  client.get("/my/web/page/")
  csrf_token = client.cookies[token].value
  assetEqual(token, csrf_token)
  </code></pre>