ILIAS  trunk Revision v11.0_alpha-2662-g519ff7d528f
LSSettingsTest Class Reference
+ Inheritance diagram for LSSettingsTest:
+ Collaboration diagram for LSSettingsTest:

Public Member Functions

 testCreate ()
 
 testWithAbstract (ilLearningSequenceSettings $object)
 
 testWithExtro (ilLearningSequenceSettings $object)
 
 testWithAbstractImage (ilLearningSequenceSettings $object)
 
 testWithExtroImage (ilLearningSequenceSettings $object)
 
 testWithMembersGallery (ilLearningSequenceSettings $object)
 

Data Fields

const TO_OBJ_ID = 10
 
const TO_ABSTRACT = "abstract"
 
const TO_EXTRO = "extro"
 
const TO_ABSTRACT_IMAGE = "abstract/image/path"
 
const TO_EXTRO_IMAGE = "extro/image/path"
 
const TO_ONLINE = true
 
const TO_MEMBERS_GALLERY = true
 

Detailed Description

Member Function Documentation

◆ testCreate()

LSSettingsTest::testCreate ( )

Definition at line 36 of file LSSettingsTest.php.

37  {
38  $object = new ilLearningSequenceSettings(
39  self::TO_OBJ_ID,
40  self::TO_ABSTRACT,
41  self::TO_EXTRO,
42  self::TO_ABSTRACT_IMAGE,
43  self::TO_EXTRO_IMAGE,
44  self::TO_ONLINE,
45  self::TO_MEMBERS_GALLERY
46  );
47 
48  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
49  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
50  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
51  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
52  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
53  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
54 
55  return $object;
56  }
Settings for an LSO (like abstract, extro)

◆ testWithAbstract()

LSSettingsTest::testWithAbstract ( ilLearningSequenceSettings  $object)

Definition at line 59 of file LSSettingsTest.php.

References ilLearningSequenceSettings\getAbstract(), ilLearningSequenceSettings\getAbstractImage(), ilLearningSequenceSettings\getExtro(), ilLearningSequenceSettings\getExtroImage(), ilLearningSequenceSettings\getMembersGallery(), ilLearningSequenceSettings\getObjId(), and ilLearningSequenceSettings\withAbstract().

60  {
61  $new_object = $object->withAbstract("teststring");
62 
63  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
64  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
65  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
66  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
67  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
68  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
69 
70  $this->assertEquals($new_object->getObjId(), self::TO_OBJ_ID);
71  $this->assertEquals($new_object->getAbstract(), "teststring");
72  $this->assertEquals($new_object->getExtro(), self::TO_EXTRO);
73  $this->assertEquals($new_object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
74  $this->assertEquals($new_object->getExtroImage(), self::TO_EXTRO_IMAGE);
75  $this->assertEquals($new_object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
76  }
+ Here is the call graph for this function:

◆ testWithAbstractImage()

LSSettingsTest::testWithAbstractImage ( ilLearningSequenceSettings  $object)

Definition at line 99 of file LSSettingsTest.php.

References ilLearningSequenceSettings\getAbstract(), ilLearningSequenceSettings\getAbstractImage(), ilLearningSequenceSettings\getExtro(), ilLearningSequenceSettings\getExtroImage(), ilLearningSequenceSettings\getMembersGallery(), ilLearningSequenceSettings\getObjId(), and ilLearningSequenceSettings\withAbstractImage().

100  {
101  $new_object = $object->withAbstractImage("teststring");
102 
103  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
104  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
105  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
106  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
107  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
108  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
109 
110  $this->assertEquals($new_object->getObjId(), self::TO_OBJ_ID);
111  $this->assertEquals($new_object->getAbstract(), self::TO_ABSTRACT);
112  $this->assertEquals($new_object->getExtro(), self::TO_EXTRO);
113  $this->assertEquals($new_object->getAbstractImage(), "teststring");
114  $this->assertEquals($new_object->getExtroImage(), self::TO_EXTRO_IMAGE);
115  $this->assertEquals($new_object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
116  }
+ Here is the call graph for this function:

◆ testWithExtro()

LSSettingsTest::testWithExtro ( ilLearningSequenceSettings  $object)

Definition at line 79 of file LSSettingsTest.php.

References ilLearningSequenceSettings\getAbstract(), ilLearningSequenceSettings\getAbstractImage(), ilLearningSequenceSettings\getExtro(), ilLearningSequenceSettings\getExtroImage(), ilLearningSequenceSettings\getMembersGallery(), ilLearningSequenceSettings\getObjId(), and ilLearningSequenceSettings\withExtro().

80  {
81  $new_object = $object->withExtro("teststring");
82 
83  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
84  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
85  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
86  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
87  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
88  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
89 
90  $this->assertEquals($new_object->getObjId(), self::TO_OBJ_ID);
91  $this->assertEquals($new_object->getAbstract(), self::TO_ABSTRACT);
92  $this->assertEquals($new_object->getExtro(), "teststring");
93  $this->assertEquals($new_object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
94  $this->assertEquals($new_object->getExtroImage(), self::TO_EXTRO_IMAGE);
95  $this->assertEquals($new_object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
96  }
+ Here is the call graph for this function:

◆ testWithExtroImage()

LSSettingsTest::testWithExtroImage ( ilLearningSequenceSettings  $object)

Definition at line 119 of file LSSettingsTest.php.

References ilLearningSequenceSettings\getAbstract(), ilLearningSequenceSettings\getAbstractImage(), ilLearningSequenceSettings\getExtro(), ilLearningSequenceSettings\getExtroImage(), ilLearningSequenceSettings\getMembersGallery(), ilLearningSequenceSettings\getObjId(), and ilLearningSequenceSettings\withExtroImage().

120  {
121  $new_object = $object->withExtroImage("teststring");
122 
123  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
124  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
125  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
126  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
127  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
128  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
129 
130  $this->assertEquals($new_object->getObjId(), self::TO_OBJ_ID);
131  $this->assertEquals($new_object->getAbstract(), self::TO_ABSTRACT);
132  $this->assertEquals($new_object->getExtro(), self::TO_EXTRO);
133  $this->assertEquals($new_object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
134  $this->assertEquals($new_object->getExtroImage(), "teststring");
135  $this->assertEquals($new_object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
136  }
+ Here is the call graph for this function:

◆ testWithMembersGallery()

LSSettingsTest::testWithMembersGallery ( ilLearningSequenceSettings  $object)

Definition at line 139 of file LSSettingsTest.php.

References ilLearningSequenceSettings\getAbstract(), ilLearningSequenceSettings\getAbstractImage(), ilLearningSequenceSettings\getExtro(), ilLearningSequenceSettings\getExtroImage(), ilLearningSequenceSettings\getMembersGallery(), ilLearningSequenceSettings\getObjId(), and ilLearningSequenceSettings\withMembersGallery().

140  {
141  $new_object = $object->withMembersGallery(false);
142 
143  $this->assertEquals($object->getObjId(), self::TO_OBJ_ID);
144  $this->assertEquals($object->getAbstract(), self::TO_ABSTRACT);
145  $this->assertEquals($object->getExtro(), self::TO_EXTRO);
146  $this->assertEquals($object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
147  $this->assertEquals($object->getExtroImage(), self::TO_EXTRO_IMAGE);
148  $this->assertEquals($object->getMembersGallery(), self::TO_MEMBERS_GALLERY);
149 
150  $this->assertEquals($new_object->getObjId(), self::TO_OBJ_ID);
151  $this->assertEquals($new_object->getAbstract(), self::TO_ABSTRACT);
152  $this->assertEquals($new_object->getExtro(), self::TO_EXTRO);
153  $this->assertEquals($new_object->getAbstractImage(), self::TO_ABSTRACT_IMAGE);
154  $this->assertEquals($new_object->getExtroImage(), self::TO_EXTRO_IMAGE);
155  $this->assertEquals($new_object->getMembersGallery(), false);
156  }
+ Here is the call graph for this function:

Field Documentation

◆ TO_ABSTRACT

const LSSettingsTest::TO_ABSTRACT = "abstract"

Definition at line 29 of file LSSettingsTest.php.

◆ TO_ABSTRACT_IMAGE

const LSSettingsTest::TO_ABSTRACT_IMAGE = "abstract/image/path"

Definition at line 31 of file LSSettingsTest.php.

◆ TO_EXTRO

const LSSettingsTest::TO_EXTRO = "extro"

Definition at line 30 of file LSSettingsTest.php.

◆ TO_EXTRO_IMAGE

const LSSettingsTest::TO_EXTRO_IMAGE = "extro/image/path"

Definition at line 32 of file LSSettingsTest.php.

◆ TO_MEMBERS_GALLERY

const LSSettingsTest::TO_MEMBERS_GALLERY = true

Definition at line 34 of file LSSettingsTest.php.

◆ TO_OBJ_ID

const LSSettingsTest::TO_OBJ_ID = 10

Definition at line 28 of file LSSettingsTest.php.

◆ TO_ONLINE

const LSSettingsTest::TO_ONLINE = true

Definition at line 33 of file LSSettingsTest.php.


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