Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-word Chemistry warning texts #651

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -324,9 +324,7 @@ public QuestionValidationResponse validateQuestionResponse(final Question questi
if (containsError) {

// User input contains error terms.
// FIXME: This currently clashes with determining whether the submitted answer was the wrong type
// Inequality should be changed to not allow Nuclear syntax in Chemistry questions and vice versa
feedback = new Content("Your answer contains invalid syntax!");
feedback = new Content("We are unable to interpret your answer; it may not be chemically valid or be in a format we don't recognise.");

} else if (closestMatch != null && closestMatchType == MatchType.EXACT) {

Expand All @@ -337,27 +335,27 @@ public QuestionValidationResponse validateQuestionResponse(final Question questi
} else if (isNuclear && !chemistryQuestion.isNuclear()) {

// Nuclear/Chemistry mismatch in all correct answers.
feedback = new Content("This question is about Chemistry.");
feedback = new Content("This question is about Chemistry!");

} else if (chemistryQuestion.isNuclear() && !isNuclear) {
} else if (!isNuclear && chemistryQuestion.isNuclear() ) {

// Nuclear/Chemistry mismatch in all correct answers.
feedback = new Content("This question is about Nuclear Physics.");
feedback = new Content("This question is about Nuclear Physics!");

} else if (!isEquation && allEquation) {

// Equation/Expression mismatch in all correct answers.
feedback = new Content("Your answer is an expression but we expected an equation.");
feedback = new Content("Your answer is an expression but we expected an equation!");

} else if (isEquation && allExpression) {

// Equation/Expression mismatch in all correct answers.
feedback = new Content("Your answer is an equation or a term but we expected an expression.");
feedback = new Content("Your answer is an equation or a term but we expected an expression!");

} else if (isEquation && balancedKnownFlag && !isBalanced) {

// Input is an unbalanced equation.
feedback = new Content("Your equation is unbalanced.");
feedback = new Content("Your equation is unbalanced!");

} else if (isNuclear && validityKnownFlag && !isValid) {

Expand All @@ -373,7 +371,7 @@ public QuestionValidationResponse validateQuestionResponse(final Question questi
if (closestResponse.get("sameElements").equals(false)) {

// Wrong element/compound
feedback = new Content("Check your elements!");
feedback = new Content("Check that you have all the correct atoms present and in the right place!");

} else if (closestResponse.get("sameCoefficient").equals(false)) {

Expand All @@ -388,7 +386,7 @@ public QuestionValidationResponse validateQuestionResponse(final Question questi
} else if (!isNuclear && closestResponse.get("sameArrow").equals(false)) {

// Wrong arrow
feedback = new Content("What type of reaction is this?");
feedback = new Content("Check your reaction arrow!");

} else if (!isNuclear && closestResponse.get("sameBrackets").equals(false)) {

Expand Down
Loading