ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\Skill\Profile\SkillProfileTest Class Reference
+ Inheritance diagram for ILIAS\Skill\Profile\SkillProfileTest:
+ Collaboration diagram for ILIAS\Skill\Profile\SkillProfileTest:

Public Member Functions

 testProfileProperties ()
 
 testProfileLevelProperties ()
 
 testProfileCompletionProperties ()
 
 testProfileUserAssignmentProperties ()
 
 testProfileRoleAssignmentProperties ()
 
 testProfileAssignmentInstanceOfInterface ()
 

Protected Member Functions

 setUp ()
 

Protected Attributes

SkillProfile $profile
 
SkillProfileLevel $profile_level
 
SkillProfileCompletion $profile_completion
 
SkillProfileUserAssignment $profile_user_assignment
 
SkillProfileRoleAssignment $profile_role_assignment
 

Detailed Description

Author
Thomas Famula famul.nosp@m.a@le.nosp@m.ifos..nosp@m.de

Definition at line 28 of file SkillProfileTest.php.

Member Function Documentation

◆ setUp()

ILIAS\Skill\Profile\SkillProfileTest::setUp ( )
protected

Definition at line 36 of file SkillProfileTest.php.

36 : void
37 {
38 parent::setUp();
39
40 $this->profile = new SkillProfile(
41 11,
42 "My profile",
43 "This is my profile",
44 12,
45 "my_profile_image_id"
46 );
47 $this->profile_level = new SkillProfileLevel(
48 21,
49 22,
50 23,
51 24,
52 25
53 );
54 $this->profile_completion = new SkillProfileCompletion(
55 31,
56 32,
57 "1999-01-01 12:12:12",
58 true
59 );
60 $this->profile_user_assignment = new SkillProfileUserAssignment(
61 "My user",
62 41
63 );
64 $this->profile_role_assignment = new SkillProfileRoleAssignment(
65 "My role",
66 51,
67 "My object",
68 "My object type",
69 52
70 );
71 }

References ILIAS\Repository\profile().

+ Here is the call graph for this function:

◆ testProfileAssignmentInstanceOfInterface()

ILIAS\Skill\Profile\SkillProfileTest::testProfileAssignmentInstanceOfInterface ( )

Definition at line 199 of file SkillProfileTest.php.

199 : void
200 {
203
204 $this->assertInstanceOf(SkillProfileAssignmentInterface::class, $pu);
205 $this->assertInstanceOf(SkillProfileAssignmentInterface::class, $pr);
206 }
SkillProfileUserAssignment $profile_user_assignment
SkillProfileRoleAssignment $profile_role_assignment

References ILIAS\Skill\Profile\SkillProfileTest\$profile_role_assignment, and ILIAS\Skill\Profile\SkillProfileTest\$profile_user_assignment.

◆ testProfileCompletionProperties()

ILIAS\Skill\Profile\SkillProfileTest::testProfileCompletionProperties ( )

Definition at line 129 of file SkillProfileTest.php.

129 : void
130 {
132
133 $this->assertEquals(
134 31,
135 $pc->getProfileId()
136 );
137 $this->assertEquals(
138 32,
139 $pc->getUserId()
140 );
141 $this->assertEquals(
142 "1999-01-01 12:12:12",
143 $pc->getDate()
144 );
145 $this->assertEquals(
146 true,
147 $pc->getFulfilled()
148 );
149 }
SkillProfileCompletion $profile_completion

References ILIAS\Skill\Profile\SkillProfileTest\$profile_completion.

◆ testProfileLevelProperties()

ILIAS\Skill\Profile\SkillProfileTest::testProfileLevelProperties ( )

Definition at line 103 of file SkillProfileTest.php.

103 : void
104 {
106
107 $this->assertEquals(
108 21,
109 $pl->getProfileId()
110 );
111 $this->assertEquals(
112 22,
113 $pl->getBaseSkillId()
114 );
115 $this->assertEquals(
116 23,
117 $pl->getTrefId()
118 );
119 $this->assertEquals(
120 24,
121 $pl->getLevelId()
122 );
123 $this->assertEquals(
124 25,
125 $pl->getOrderNr()
126 );
127 }

References ILIAS\Skill\Profile\SkillProfileTest\$profile_level.

◆ testProfileProperties()

ILIAS\Skill\Profile\SkillProfileTest::testProfileProperties ( )

Definition at line 73 of file SkillProfileTest.php.

73 : void
74 {
75 $p = $this->profile;
76
77 $this->assertEquals(
78 11,
79 $p->getId()
80 );
81 $this->assertEquals(
82 "My profile",
83 $p->getTitle()
84 );
85 $this->assertEquals(
86 "This is my profile",
87 $p->getDescription()
88 );
89 $this->assertEquals(
90 12,
91 $p->getSkillTreeId()
92 );
93 $this->assertEquals(
94 "my_profile_image_id",
95 $p->getImageId()
96 );
97 $this->assertEquals(
98 0,
99 $p->getRefId()
100 );
101 }

References ILIAS\Skill\Profile\SkillProfileTest\$profile.

◆ testProfileRoleAssignmentProperties()

ILIAS\Skill\Profile\SkillProfileTest::testProfileRoleAssignmentProperties ( )

Definition at line 169 of file SkillProfileTest.php.

169 : void
170 {
172
173 $this->assertEquals(
174 "role",
175 $pr->getType()
176 );
177 $this->assertEquals(
178 "My role",
179 $pr->getName()
180 );
181 $this->assertEquals(
182 51,
183 $pr->getId()
184 );
185 $this->assertEquals(
186 "My object",
187 $pr->getObjTitle()
188 );
189 $this->assertEquals(
190 "My object type",
191 $pr->getObjType()
192 );
193 $this->assertEquals(
194 52,
195 $pr->getObjId()
196 );
197 }

References ILIAS\Skill\Profile\SkillProfileTest\$profile_role_assignment.

◆ testProfileUserAssignmentProperties()

ILIAS\Skill\Profile\SkillProfileTest::testProfileUserAssignmentProperties ( )

Definition at line 151 of file SkillProfileTest.php.

151 : void
152 {
154
155 $this->assertEquals(
156 "user",
157 $pu->getType()
158 );
159 $this->assertEquals(
160 "My user",
161 $pu->getName()
162 );
163 $this->assertEquals(
164 41,
165 $pu->getId()
166 );
167 }

References ILIAS\Skill\Profile\SkillProfileTest\$profile_user_assignment.

Field Documentation

◆ $profile

SkillProfile ILIAS\Skill\Profile\SkillProfileTest::$profile
protected

◆ $profile_completion

SkillProfileCompletion ILIAS\Skill\Profile\SkillProfileTest::$profile_completion
protected

◆ $profile_level

SkillProfileLevel ILIAS\Skill\Profile\SkillProfileTest::$profile_level
protected

◆ $profile_role_assignment

◆ $profile_user_assignment


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