test_question: Run a whole question and report aggregate results

Description Usage Arguments Value

View source: R/questions.R

Description

This function is the equivalent of the pltest.R script which, given a directory runs the tests file therein and reports the results in a JSON file for PrairieLearn to consume.

Usage

1
2
test_question(tests_dir = "/grade/tests/tests",
  results_file = "results.json")

Arguments

tests_dir

Directory containing the test files for a question

results_file

JSON file into which results are written

Value

The results data.frame is returned, but the functions is invoked for its side-effect of creating the JSON file


stat447/plr documentation built on Dec. 23, 2021, 5:24 a.m.