17 if (
defined(
'ILIAS_PHPUNIT_CONTEXT')) {
18 include_once(
"./Services/PHPUnit/classes/class.ilUnitUtil.php");
19 ilUnitUtil::performInitialisation();
21 chdir(dirname(__FILE__));
29 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
35 $this->assertNotNull($instance);
41 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
46 $instance->setLowerBound($expected);
47 $actual = $instance->getLowerBound();
50 $this->assertEquals($expected, $actual);
56 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
61 $instance->setLowerBound(4);
62 $actual = $instance->getLowerBound();
65 $this->assertEquals($expected, $actual);
71 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
76 $instance->setLowerBound(
'test');
77 $actual = $instance->getLowerBound();
80 $this->assertEquals($expected, $actual);
86 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
91 $instance->setUpperBound($expected);
92 $actual = $instance->getUpperBound();
95 $this->assertEquals($expected, $actual);
101 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
106 $instance->setUpperBound(2);
107 $actual = $instance->getUpperBound();
110 $this->assertEquals($expected, $actual);
116 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerCloze.php';
121 $instance->setUpperBound(
'test');
122 $actual = $instance->getUpperBound();
125 $this->assertEquals($expected, $actual);
Class for cloze question numeric answers.
test_setGetUpperBound_nonNumericShouldSetAnswertext()
test_constructorShouldReturnInstance()
test_setGetLowerBound_nonNumericShouldSetAnswertext()
test_setGetUpperBound_smallerThanAnswerShouldSetAnswertext()
test_setGetLowerBond_GreaterThanAnswerShouldSetAnswertext()
defined( 'APPLICATION_ENV')||define( 'APPLICATION_ENV'