'Dry method for adding fake course enrollment information to fake
data API and enroll the student in the course.'

def assert_add_modes_with_enrollment(self, enrollment_mode):

    fake_data_api.add_course(self.COURSE_ID, course_modes=['honor', 'verified', 'audit'])
    result = api.add_enrollment(self.USERNAME, self.COURSE_ID, mode=enrollment_mode)
    get_result = api.get_enrollment(self.USERNAME, self.COURSE_ID)
    self.assertEquals(result, get_result)
    fake_data_api.set_expired_mode(self.COURSE_ID)
