Unit tests.
More...
◆ setUp()
assAnswerOrderingTest::setUp |
( |
| ) |
|
|
protected |
Reimplemented from assBaseTestCase.
Definition at line 14 of file assAnswerOrderingTest.php.
14 : void
15 {
16 if (defined('ILIAS_PHPUNIT_CONTEXT')) {
17 include_once("./Services/PHPUnit/classes/class.ilUnitUtil.php");
18 ilUnitUtil::performInitialisation();
19 } else {
20 chdir(dirname(__FILE__));
21 chdir('../../../');
22 }
23 }
◆ test_instantiateObject_shouldReturnInstance()
assAnswerOrderingTest::test_instantiateObject_shouldReturnInstance |
( |
| ) |
|
Definition at line 25 of file assAnswerOrderingTest.php.
26 {
27
28 require_once './Modules/TestQuestionPool/classes/questions/class.ilAssOrderingElement.php';
29
30
32
33 $this->assertInstanceOf('ilAssOrderingElement', $instance);
34 }
◆ test_setGetAnswerId()
assAnswerOrderingTest::test_setGetAnswerId |
( |
| ) |
|
Definition at line 51 of file assAnswerOrderingTest.php.
52 {
53
54 require_once './Modules/TestQuestionPool/classes/questions/class.ilAssOrderingElement.php';
56 $expected = 13579;
57
58
59 $instance->setId($expected);
60 $actual = $instance->getId();
61
62
63 $this->assertEquals($expected, $actual);
64 }
◆ test_setGetOrdeingDepth()
assAnswerOrderingTest::test_setGetOrdeingDepth |
( |
| ) |
|
Definition at line 67 of file assAnswerOrderingTest.php.
68 {
69
70 require_once './Modules/TestQuestionPool/classes/questions/class.ilAssOrderingElement.php';
72 $expected = 13579;
73
74
75 $instance->setIndentation($expected);
76 $actual = $instance->getIndentation();
77
78
79 $this->assertEquals($expected, $actual);
80 }
◆ test_setGetRandomId()
assAnswerOrderingTest::test_setGetRandomId |
( |
| ) |
|
Definition at line 36 of file assAnswerOrderingTest.php.
37 {
38
39 require_once './Modules/TestQuestionPool/classes/questions/class.ilAssOrderingElement.php';
41 $expected = 13579;
42
43
44 $instance->setRandomIdentifier($expected);
45 $actual = $instance->getRandomIdentifier();
46
47
48 $this->assertEquals($expected, $actual);
49 }
◆ $backupGlobals
assAnswerOrderingTest::$backupGlobals = false |
|
protected |
The documentation for this class was generated from the following file: