aboutsummaryrefslogtreecommitdiff
path: root/tests/helper.php
diff options
context:
space:
mode:
authorJean-Michel Vedrine <vedrine@vedrine.org>2018-01-01 19:10:49 +0100
committerJean-Michel Vedrine <vedrine@vedrine.org>2018-01-01 19:10:49 +0100
commit294edec77a967e743631bfe2cde6b8ecc47b980c (patch)
tree992d1425dc9ccaaea338b8a43196a28e6f16b673 /tests/helper.php
parent256a9808276e420bc7ee6168f04ab31b6cfe4d44 (diff)
Test multiplication display
Diffstat (limited to 'tests/helper.php')
-rw-r--r--tests/helper.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/tests/helper.php b/tests/helper.php
index 97639bc..e36ed9c 100644
--- a/tests/helper.php
+++ b/tests/helper.php
@@ -97,8 +97,7 @@ class qtype_algebra_test_helper extends question_test_helper {
/**
* Gets the question form data for a algebra question with with correct
- * answer 'frog', partially correct answer 'toad' and defaultmark 1.
- * This question also has a '*' match anything answer.
+ * answer '7*x' and defaultmark 1.
* @return stdClass
*/
public function get_algebra_question_form_data_simplemath() {
@@ -109,8 +108,17 @@ class qtype_algebra_test_helper extends question_test_helper {
'format' => FORMAT_HTML);
$form->defaultmark = 1.0;
$form->generalfeedback = array('text' => 'Generalfeedback: (P + Q)(x) = 7x.', 'format' => FORMAT_HTML);
+ $form->compareby = 'eval';
+ $form->nchecks = 10;
+ $form->tolerance = 0.001;
+ $form->allowedfuncs = '';
+ $form->disallow = '';
+ $form->answerprefix = '';
$form->answer = array('7*x');
$form->fraction = array('1.0');
+ $form->variable = array('x');
+ $form->varmin = array('-5');
+ $form->varmax = array('5');
$form->feedback = array(
array('text' => 'This is a very good answer.', 'format' => FORMAT_HTML),
);