'Test courseware access page without passing entrance exam'

def test_courseware_page_access_without_passing_entrance_exam(self):

    url = reverse('courseware_chapter', kwargs={'course_id': unicode(self.course.id), 'chapter': self.chapter.url_name})
    response = self.client.get(url)
    expected_url = reverse('courseware_section', kwargs={'course_id': unicode(self.course.id), 'chapter': self.entrance_exam.location.name, 'section': self.exam_1.location.name})
    self.assertRedirects(response, expected_url, status_code=302, target_status_code=200)
