def should_be_callable_when_authenticated(self, user, url=None):
if not url:<EOL><INDENT>url = self.get_url()<EOL><DEDENT>self.login(user)<EOL>resp = self.client.get(url, data=self.get_data_payload())<EOL>self.assertEqual(resp.status_code, <NUM_LIT:200>)<EOL>return resp<EOL>
Tests if the view returns 200 when the user is logged in.

:param user: A ``User`` instance.
:param url: A string representing the URL to be called. If ``None``,
  the return value of ``get_url()`` will be used.