numbas / Numbas

A completely browser-based e-assessment/e-learning system, with an emphasis on mathematics
http://www.numbas.org.uk
Apache License 2.0
199 stars 118 forks source link

Code parts do not test whether the supplied correct answer passes the tests #944

Closed aarchiba closed 1 year ago

aarchiba commented 1 year ago

Code parts have a space for a correct answer to be supplied. They also carry out validation tests and correctness tests on the student's code. When creating a question, it would be very helpful if the machinery checked that the supposed correct answer passes the tests the student's answer is supposed to.

christianp commented 1 year ago

This is a good suggestion, and I don't think this is unique to the code part type.

There's an existing issue in the editor repo about this, numbas/editor#502. For this part type, and any other that uses pre-submit tasks, we'd need to make sure not to test too often so the whole thing doesn't grind to a halt.