-
Notifications
You must be signed in to change notification settings - Fork 10
Customizing assertions is slightly broken #137
Copy link
Copy link
Open
Labels
Assertions ToolIssues pertaining to the Assertions tool (declarative statements about student code)Issues pertaining to the Assertions tool (declarative statements about student code)bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers
Metadata
Metadata
Assignees
Labels
Assertions ToolIssues pertaining to the Assertions tool (declarative statements about student code)Issues pertaining to the Assertions tool (declarative statements about student code)bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers
Type
Fields
Give feedbackNo fields configured for issues without a type.
You're supposed to be able to customize runtime (and static) assertions in a few different ways: providing custom assertion, explanation, expected_verb, aggregate_verb, etc. However, this functionality is not working correctly because the assertions' conditions do not catch
kwargs. That part is fairly easy to fix (though a little tedious), but this also exposed a minor issue: the way that we are handling the assertion, we are not actually interpolating variables. So you couldn't provide a message like "{left} was not {right}". Seems to me like we should probably supportassertion_template,explanation_template, etc. We also need to makeexpected_verbandaggregate_verbavailable as parameters, not just class fields (and corresponding _template) versions.