-
Notifications
You must be signed in to change notification settings - Fork 350
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle missing numeric input answer values
- Loading branch information
1 parent
4172a32
commit 2916acb
Showing
5 changed files
with
233 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
115 changes: 115 additions & 0 deletions
115
...src/util/parse-perseus-json/regression-tests/data/numeric-input-answer-without-value.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
{ | ||
"question": { | ||
"content": "$\\bigg(\\dfrac{2}{3} \\bigg)^3 =$ [[☃ expression 1]]", | ||
"images": {}, | ||
"widgets": { | ||
"numeric-input 1": { | ||
"type": "numeric-input", | ||
"alignment": "default", | ||
"static": false, | ||
"graded": true, | ||
"options": { | ||
"answers": [ | ||
{ | ||
"status": "correct", | ||
"message": "", | ||
"simplify": "required", | ||
"strict": false, | ||
"maxError": null, | ||
"answerForms": [ | ||
"proper", | ||
"improper" | ||
] | ||
} | ||
], | ||
"size": "normal", | ||
"coefficient": false, | ||
"labelText": "", | ||
"rightAlign": false, | ||
"static": false, | ||
"multipleNumberInput": false | ||
}, | ||
"version": { | ||
"major": 0, | ||
"minor": 0 | ||
} | ||
}, | ||
"expression 1": { | ||
"options": { | ||
"answerForms": [ | ||
{ | ||
"considered": "correct", | ||
"form": true, | ||
"key": 0, | ||
"simplify": true, | ||
"value": "\\frac{8}{27}", | ||
"times": false, | ||
"functions": [ | ||
"f", | ||
"g", | ||
"h" | ||
], | ||
"buttonSets": [ | ||
"basic" | ||
], | ||
"buttonsVisible": "focused", | ||
"linterContext": { | ||
"contentType": "", | ||
"highlightLint": false, | ||
"paths": [], | ||
"stack": [] | ||
} | ||
} | ||
], | ||
"times": false, | ||
"buttonSets": [ | ||
"basic" | ||
], | ||
"functions": [ | ||
"f", | ||
"g", | ||
"h" | ||
], | ||
"static": false | ||
}, | ||
"type": "expression", | ||
"version": { | ||
"major": 1, | ||
"minor": 0 | ||
}, | ||
"graded": true, | ||
"alignment": "default", | ||
"static": false | ||
} | ||
} | ||
}, | ||
"answerArea": { | ||
"calculator": false, | ||
"chi2Table": false, | ||
"financialCalculatorMonthlyPayment": false, | ||
"financialCalculatorTotalAmount": false, | ||
"financialCalculatorTimeToPayOff": false, | ||
"periodicTable": false, | ||
"periodicTableWithKey": false, | ||
"tTable": false, | ||
"zTable": false | ||
}, | ||
"itemDataVersion": { | ||
"major": 0, | ||
"minor": 1 | ||
}, | ||
"hints": [ | ||
{ | ||
"replace": false, | ||
"content": "$\\bigg(\\dfrac{2}{3} \\bigg)^3 =\\dfrac{2}{3}\\times \\dfrac{2}{3}\\times\\dfrac{2}{3}$\n\nLet's perform this multiplication to find the answer.", | ||
"images": {}, | ||
"widgets": {} | ||
}, | ||
{ | ||
"replace": false, | ||
"content": "On multiplying, we see that\n\n$\\dfrac{2}{3}\\times \\dfrac{2}{3}\\times\\dfrac{2}{3}=\\boxed{\\dfrac{8}{27}}$.", | ||
"images": {}, | ||
"widgets": {} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters