'Deleting a question while logged out redirects to login.'

def test_delete_question_logged_out(self):

    self.client.logout()
    response = get(self.client, 'questions.delete', args=[self.question.id])
    redirect = response.redirect_chain[0]
    eq_(302, redirect[1])
    eq_(('http://testserver/%s%s?next=/en-US/questions/%s/delete' % (settings.LANGUAGE_CODE, settings.LOGIN_URL, self.question.id)), redirect[0])
    response = post(self.client, 'questions.delete', args=[self.question.id])
    redirect = response.redirect_chain[0]
    eq_(302, redirect[1])
    eq_(('http://testserver/%s%s?next=/en-US/questions/%s/delete' % (settings.LANGUAGE_CODE, settings.LOGIN_URL, self.question.id)), redirect[0])
