'Configure a credit course and its requirements.
By default, add a single requirement (minimum grade)
that the user has satisfied.'

def _configure_credit(self, course_key=None):

    course_key = (course_key or self.course_key)
    credit_course = self.add_credit_course(course_key=course_key)
    requirement = CreditRequirement.objects.create(course=credit_course, namespace='grade', name='grade', active=True)
    status = CreditRequirementStatus.objects.create(username=self.USER_INFO['username'], requirement=requirement)
    status.status = 'satisfied'
    status.reason = {'final_grade': self.FINAL_GRADE}
    status.save()
    CreditEligibility.objects.create(username=self.USER_INFO['username'], course=CreditCourse.objects.get(course_key=course_key))
