Permalink
Fetching contributors…
Cannot retrieve contributors at this time
44 lines (41 sloc) 1.63 KB
{
// explicitly grab the necessary submitted files for static analysis
"autograding" : {
"submission_to_runner" : [ "*.cpp", "*.c", "*.hpp", "*.h", "*.c", "*.hpp" ]
},
// Static analysis can also be performed upon C++ code.
// Here, no compilation is performed at all; instead, student code is examined to
// ensure that it does not use either the "goto" or "auto" keywords.
"testcases" : [
{
"title" : "Check for goto and auto",
"command" : [ "submitty_count token -l c Goto *.cpp",
"submitty_count token -l c Auto *.cpp" ],
"points" : 2,
"validation" : [
{
// number of goto must be 0
"method" : "intComparison",
"actual_file" : "STDOUT_0.txt",
"description" : "Number of `goto`",
"comparison" : "eq",
"term" : 0,
"failure_message" : "You must not use the `goto` keyword.",
"show_message" : "on_failure",
"show_actual" : "never"
},
{
// number of auto must be 0
"method" : "intComparison",
"actual_file" : "STDOUT_1.txt",
"description" : "Number of `auto`",
"comparison" : "eq",
"term" : 0,
"failure_message" : "You must not use the `auto` keyword.",
"show_message" : "on_failure",
"show_actual" : "never"
}
]
}
]
}