'Tests passing an invalid category'

def test_category_invalid(self):

    ques = QuestionFactory(title=u'q1    audio')
    ques.tags.add(u'desktop')
    ans = AnswerFactory(question=ques)
    AnswerVoteFactory(answer=ans, helpful=True)
    d1 = DocumentFactory(title=u'd1    audio', locale=u'en-US', category=10, is_archived=False, tags=[u'desktop'])
    ApprovedRevisionFactory(document=d1)
    self.refresh()
    qs = {'a': 1, 'w': 3, 'format': 'json', 'category': 'invalid'}
    response = self.client.get(reverse('search.advanced'), qs)
    eq_(2, json.loads(response.content)['total'])
