'If the user has an inactive enrollment for the course, the view should behave as if the
user has no enrollment.'

def test_existing_inactive_enrollment(self):

    CourseEnrollment.enroll(self.user, self.course.id)
    CourseEnrollment.unenroll(self.user, self.course.id, True)
    self.assertFalse(CourseEnrollment.is_enrolled(self.user, self.course.id))
    self.assertIsNotNone(get_enrollment(self.user.username, unicode(self.course.id)))
    with mock_create_basket():
        self._test_successful_ecommerce_api_call(is_completed=False)
