'Verify status information.
Arguments:
status_div (bool): check presence of status div
status_class (bool): check presence of status class'

def assert_status(self, status_div=False, status_class=False):

    cases = [('correct', 'correct'), ('unsubmitted', 'unanswered'), ('submitted', 'submitted'), ('incorrect', 'incorrect'), ('incomplete', 'incorrect')]
    for (context_status, div_class) in cases:
        self.context['status'] = Status(context_status)
        xml = self.render_to_xml(self.context)
        if status_div:
            xpath = ("//div[normalize-space(@class)='%s']" % div_class)
            self.assert_has_xpath(xml, xpath, self.context)
        self.assert_has_text(xml, "//span[@class='status    {}']/span[@class='sr']".format((div_class if status_class else '')), self.context['status'].display_name)
