Unit tests.
More...
◆ setUp()
assAnswerMatchingTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 15 of file assAnswerMatchingTest.php.
References defined.
17 if (
defined(
'ILIAS_PHPUNIT_CONTEXT')) {
18 include_once(
"./Services/PHPUnit/classes/class.ilUnitUtil.php");
19 ilUnitUtil::performInitialisation();
21 chdir(dirname(__FILE__));
defined( 'APPLICATION_ENV')||define( 'APPLICATION_ENV'
◆ test_instantiateObjectSimple()
assAnswerMatchingTest::test_instantiateObjectSimple |
( |
| ) |
|
Definition at line 26 of file assAnswerMatchingTest.php.
29 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
35 $this->assertInstanceOf(
'ASS_AnswerMatching', $instance);
Class for matching question answers.
◆ test_setGetDefinition()
assAnswerMatchingTest::test_setGetDefinition |
( |
| ) |
|
Definition at line 113 of file assAnswerMatchingTest.php.
116 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
118 $expected =
'Definition is this.';
121 $instance->setDefinition($expected);
122 $actual = $instance->getDefinition();
125 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetDefinitionId()
assAnswerMatchingTest::test_setGetDefinitionId |
( |
| ) |
|
Definition at line 128 of file assAnswerMatchingTest.php.
131 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
136 $instance->setDefinitionId($expected);
137 $actual = $instance->getDefinitionId();
140 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetPicture()
assAnswerMatchingTest::test_setGetPicture |
( |
| ) |
|
Definition at line 68 of file assAnswerMatchingTest.php.
71 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
73 $expected =
'/link/to/image?';
76 $instance->setPicture($expected);
77 $actual = $instance->getPicture();
80 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetPictureId()
assAnswerMatchingTest::test_setGetPictureId |
( |
| ) |
|
Definition at line 83 of file assAnswerMatchingTest.php.
86 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
91 $instance->setPictureId($expected);
92 $actual = $instance->getPictureId();
95 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetPictureId_NegativeShouldNotSetValue()
assAnswerMatchingTest::test_setGetPictureId_NegativeShouldNotSetValue |
( |
| ) |
|
Definition at line 98 of file assAnswerMatchingTest.php.
101 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
106 $instance->setPictureId(-47);
107 $actual = $instance->getPictureId();
110 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetPoints()
assAnswerMatchingTest::test_setGetPoints |
( |
| ) |
|
Definition at line 38 of file assAnswerMatchingTest.php.
41 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
46 $instance->setPoints($expected);
47 $actual = $instance->getPoints();
50 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ test_setGetTermId()
assAnswerMatchingTest::test_setGetTermId |
( |
| ) |
|
Definition at line 53 of file assAnswerMatchingTest.php.
56 require_once
'./Modules/TestQuestionPool/classes/class.assAnswerMatching.php';
61 $instance->setTermId($expected);
62 $actual = $instance->getTermId();
65 $this->assertEquals($expected, $actual);
Class for matching question answers.
◆ $backupGlobals
assAnswerMatchingTest::$backupGlobals = false |
|
protected |
The documentation for this class was generated from the following file: