ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
assAnswerOrderingTest Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for assAnswerOrderingTest:
+ Collaboration diagram for assAnswerOrderingTest:

Public Member Functions

 test_instantiateObject_shouldReturnInstance ()
 
 test_setGetRandomId ()
 
 test_setGetAnswerId ()
 
 test_setGetOrdeingDepth ()
 

Protected Member Functions

 setUp ()
 
- Protected Member Functions inherited from assBaseTestCase
 setUp ()
 
 tearDown ()
 
 setGlobalVariable (string $name, $value)
 
 getGlobalTemplateMock ()
 
 getDatabaseMock ()
 
 getIRSSMock ()
 
 getFileDeliveryMock ()
 
 getIliasMock ()
 
 addGlobal_uiFactory ()
 
 addGlobal_uiRenderer ()
 

Protected Attributes

 $backupGlobals = false
 
- Protected Attributes inherited from assBaseTestCase
Container $dic = null
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Unit tests

Author
Maximilian Becker mbeck.nosp@m.er@d.nosp@m.ataba.nosp@m.y.de

Definition at line 26 of file assAnswerOrderingTest.php.

Member Function Documentation

◆ setUp()

assAnswerOrderingTest::setUp ( )
protected

Definition at line 30 of file assAnswerOrderingTest.php.

30  : void
31  {
32  chdir(dirname(__FILE__));
33  chdir('../../../');
34  }

◆ test_instantiateObject_shouldReturnInstance()

assAnswerOrderingTest::test_instantiateObject_shouldReturnInstance ( )

Definition at line 36 of file assAnswerOrderingTest.php.

36  : void
37  {
38  // Act
39  $instance = new ilAssOrderingElement();
40 
41  $this->assertInstanceOf('ilAssOrderingElement', $instance);
42  }

◆ test_setGetAnswerId()

assAnswerOrderingTest::test_setGetAnswerId ( )

Definition at line 57 of file assAnswerOrderingTest.php.

57  : void
58  {
59  $instance = new ilAssOrderingElement();
60  $expected = 13579;
61 
62  // Act
63  $instance->setId($expected);
64  $actual = $instance->getId();
65 
66  // Assert
67  $this->assertEquals($expected, $actual);
68  }

◆ test_setGetOrdeingDepth()

assAnswerOrderingTest::test_setGetOrdeingDepth ( )

Definition at line 71 of file assAnswerOrderingTest.php.

71  : void
72  {
73  $instance = new ilAssOrderingElement();
74  $expected = 13579;
75 
76  // Act
77  $instance->setIndentation($expected);
78  $actual = $instance->getIndentation();
79 
80  // Assert
81  $this->assertEquals($expected, $actual);
82  }

◆ test_setGetRandomId()

assAnswerOrderingTest::test_setGetRandomId ( )

Definition at line 44 of file assAnswerOrderingTest.php.

44  : void
45  {
46  $instance = new ilAssOrderingElement();
47  $expected = 13579;
48 
49  // Act
50  $instance->setRandomIdentifier($expected);
51  $actual = $instance->getRandomIdentifier();
52 
53  // Assert
54  $this->assertEquals($expected, $actual);
55  }

Field Documentation

◆ $backupGlobals

assAnswerOrderingTest::$backupGlobals = false
protected

Definition at line 28 of file assAnswerOrderingTest.php.


The documentation for this class was generated from the following file: