'Initial data setup'

def setUp(self):

    super(TestHandleItemDeleted, self).setUp()
    self.course = CourseFactory.create()
    self.course.enable_subsection_gating = True
    self.course.save()
    self.chapter = ItemFactory.create(parent=self.course, category='chapter', display_name='Chapter')
    self.open_seq = ItemFactory.create(parent=self.chapter, category='sequential', display_name='Open    Sequential')
    self.gated_seq = ItemFactory.create(parent=self.chapter, category='sequential', display_name='Gated    Sequential')
    gating_api.add_prerequisite(self.course.id, self.open_seq.location)
    gating_api.set_required_content(self.course.id, self.gated_seq.location, self.open_seq.location, 100)
