We are experimenting and evaluating GitHub Classroom and GitHub Actions for "autograding".
In our assignment students get points if unit tests are passed. So the autograding.json is comparably simple running mvn test -Dtest=testClass#testmethod
.
In the default setup I am unhappy with the following points:
GitHub (Actions) sends you a mail if the build (i.e. test) fails, but you do not receive a mail, if the test succeeds. It would be very nice if students get a feedback when they pass the autograding (i.e. unit test). How can this be done?
GitHub (Actions) does not provide any details in the mail, you have to visit the actions page. It would be nicer if you could supply the number of points and maybe some one-line explanation of the error. How can this be done?
To illustrate what I would like: it would be nice if the JSON allows to specify a feedback message upon success and a feedback message upon failure and the GitHub Action mail should contain this text (if that is not possible, there should be a nicely formatted web-page displaying this text). Unfortunately I did not find any documentation on the JSON. Is there any documentation of the autograde.json?
I am also interested in other options.
Here is an example for the autograde.json currently used by us:
{
"tests": [
{
"name": "Unit Tests - Testing your Application: DoubleVector - BasicFunctionality",
"setup": "",
"run": "mvn -q -B -Dtest=DoubleVectorFromArrayTest#testBasicFunctionality test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 0.5
},
{
"name": "Unit Tests - Testing your Application: DoubleVector - Accuracy",
"setup": "",
"run": "mvn -q -B -Dtest=DoubleVectorFromArrayTest#testAccuracy test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 0.5
},
{
"name": "Unit Tests - Testing your Application: QuadraticEuation",
"setup": "",
"run": "mvn -q -B -Dtest=QuadraticEuationFromCoefficientsTest test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 1
}
]
}
GHA doesn't provide such a functionality out of the box. Instead, you need to either implement it by your own, or use an existing action from the marketplace. This is one example, which lets you send emails via smpt. (Note: I didn't use the linked action myself, but expect it to work).