Skip to content
Snippets Groups Projects
Unverified Commit dfc22f9b authored by Chris Sangwin's avatar Chris Sangwin Committed by GitHub
Browse files

Update validators.mac

Fix typo in test case.
parent c555eaf0
No related branches found
No related tags found
No related merge requests found
...@@ -37,7 +37,7 @@ s_test_case(validate_underscore(1+a_1), "Underscore characters are not permitted ...@@ -37,7 +37,7 @@ s_test_case(validate_underscore(1+a_1), "Underscore characters are not permitted
validate_all_one_letter_variables(ex) := if not(is(ev(lmax(map(lambda([ex2],slength(string(ex2))),listofvars(ex))),simp)>1)) then "" validate_all_one_letter_variables(ex) := if not(is(ev(lmax(map(lambda([ex2],slength(string(ex2))),listofvars(ex))),simp)>1)) then ""
else "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter."; else "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter.";
s_test_case(validate_all_one_letter_variables(1, ""); s_test_case(validate_all_one_letter_variables(1), "");
s_test_case(validate_all_one_letter_variables((A*x+B)/(x^2+1) + C/x), ""); s_test_case(validate_all_one_letter_variables((A*x+B)/(x^2+1) + C/x), "");
s_test_case(validate_all_one_letter_variables((Ax+B)/(x^2+1) + C/x), "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter."); s_test_case(validate_all_one_letter_variables((Ax+B)/(x^2+1) + C/x), "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter.");
s_test_case(validate_all_one_letter_variables((theta*x+B)/(x^2+1) + C/x), "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter."); s_test_case(validate_all_one_letter_variables((theta*x+B)/(x^2+1) + C/x), "Only single-character variable names are permitted in this input. Perhaps you forgot to use an asterisk (*) somewhere, or perhaps you used a Greek letter.");
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment