'Assert that the url loads correctly.
If expect_redirect, then also check that we were redirected.
If check_content, then check that we don\'t get
an error message about unavailable modules.'

def _assert_loads(self, django_url, kwargs, descriptor, expect_redirect=False, check_content=False):

    url = reverse(django_url, kwargs=kwargs)
    response = self.client.get(url, follow=True)
    if (response.status_code != 200):
        self.fail(('Status    %d    for    page    %s' % (response.status_code, descriptor.location)))
    if expect_redirect:
        self.assertEqual(response.redirect_chain[0][1], 302)
    if check_content:
        self.assertNotContains(response, 'this    module    is    temporarily    unavailable')
        self.assertNotIsInstance(descriptor, ErrorDescriptor)
