'Deleting the last_answer of a Question should update the question.'

def test_delete_last_answer_of_question(self):

    yesterday = (datetime.now() - timedelta(days=1))
    q = AnswerFactory(created=yesterday).question
    last_answer = q.last_answer
    a = AnswerFactory(question=q, content='Test    Answer')
    q = Question.objects.get(pk=q.id)
    eq_(q.last_answer.id, a.id)
    a.delete()
    q = Question.objects.get(pk=q.id)
    eq_(q.last_answer.id, last_answer.id)
    eq_(Answer.objects.filter(pk=a.id).count(), 0)
