Beispiel #1
0
    RESULT_DIR,
    False,
    detailed_results=setting.DETAILED_RESULT,
    compile_flags=setting.COMPILE_FLAGS,
    logging_level=setting.LOGGING_LEVEL,
)

P2 = cs_grading.Problem(HOMEWORK, 2, 'bst', 30)
P3 = cs_grading.Problem(HOMEWORK, 3, 'rotate', 30)
P4 = cs_grading.Problem(HOMEWORK, 4, 'avl', 15)

for problem, rubric in [(P2, RUBRIC_BST), (P3, RUBRIC_ROTATEBST),
                        (P4, RUBRIC_AVLBST)]:

    problem.generate_results(
        cmake_problem.cmake_problem,
        True,
        timeout=0,
    )
    if setting.GENERATE_GRADE_REPORT:
        problem.grade_problem(RUBRIC_GENERAL, rubric)
    if setting.OPEN_RESULT:
        problem.open_result(text_editor=setting.TEXT_EDITOR)

GRADER = cs_grading.Grader(GRADER_CONFIG, setting.LOGGING_LEVEL)
cs_grading.generate_grade_report(HOMEWORK,
                                 GRADER,
                                 GRADE_REPORT_DIR,
                                 overwrite=True,
                                 logging_level=setting.LOGGING_LEVEL)
Beispiel #2
0
if setting.RUN_ROTATE:
    P2.generate_results(
        rotate,
        setting.ROTATE_USE_VALGRIND,
        timeout=setting.ROTATE_TIMEOUT,)
    if setting.GENERATE_GRADE_REPORT:
        P2.grade_problem(RUBRIC_GENERAL, RUBRIC_ROTATE)
    if setting.OPEN_RESULT:
        P2.open_result(text_editor=setting.TEXT_EDITOR)

if setting.RUN_HYPERCUBE:
    P3.generate_results(
        hypercube,
        setting.HYPERCUBE_USE_VALGRIND,
        timeout=setting.HYPERCUBE_TIMEOUT,)
    if setting.GENERATE_GRADE_REPORT:
        P3.grade_problem(RUBRIC_GENERAL, RUBRIC_HYPERCUBE)
    if setting.OPEN_RESULT:
        P3.open_result(text_editor=setting.TEXT_EDITOR)

if setting.GENERATE_GRADE_REPORT:
    HOMEWORK.grade_other_deduction(RUBRIC_OTHER)
    GRADER = Grader(GRADER_CONFIG, setting.LOGGING_LEVEL)
    generate_grade_report(
        HOMEWORK,
        GRADER,
        GRADE_REPORT_DIR,
        overwrite=setting.OVERWRITE_REPORT,
        logging_level=setting.LOGGING_LEVEL)