'Create user data to be used during grade report generation.'

def _create_user_data(self, user_enroll_mode, has_passed, whitelisted, is_embargoed, verification_status, certificate_status, certificate_mode):

    user = self.create_student('u1', mode=user_enroll_mode)
    if has_passed:
        self.submit_student_answer('u1', 'test_problem', ['choice_1'])
    CertificateWhitelistFactory.create(user=user, course_id=self.course.id, whitelist=whitelisted)
    self.user_is_embargoed(user, is_embargoed)
    if (user_enroll_mode in CourseMode.VERIFIED_MODES):
        SoftwareSecurePhotoVerificationFactory.create(user=user, status=verification_status)
    GeneratedCertificateFactory.create(user=user, course_id=self.course.id, status=certificate_status, mode=certificate_mode)
    return user
