Unit tests for tree table needsInstalledILIAS.
More...
Unit tests for tree table needsInstalledILIAS.
- Author
- Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
- Version
- $Id$
Definition at line 34 of file ilMembershipTest.php.
◆ setUp()
ilMembershipTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 38 of file ilMembershipTest.php.
40 include_once(
"./Services/PHPUnit/classes/class.ilUnitUtil.php");
41 ilUnitUtil::performInitialisation();
◆ testMembership()
ilMembershipTest::testMembership |
( |
| ) |
|
Waiting list tes IL_Init.
- Parameters
-
Definition at line 50 of file ilMembershipTest.php.
References $ret, ilWaitingList\_deleteAll(), and ilWaitingList\_deleteUser().
52 include_once
'./Services/Membership/classes/class.ilWaitingList.php';
53 include_once
'./Modules/Course/classes/class.ilCourseWaitingList.php';
56 $ret = $wait->addToList(111111);
57 $this->assertEquals(
$ret,
true);
59 $wait->updateSubscriptionTime(111111, time());
60 $wait->removeFromList(111111);
62 $wait->addToList(111111);
63 $ret = $wait->isOnList(111111);
64 $this->assertEquals(
$ret,
true);
66 $wait->addToList(111111);
69 $wait->addToList(111111);
static _deleteUser($a_usr_id)
Delete user.
static _deleteAll($a_obj_id)
delete all
◆ testSubscription()
ilMembershipTest::testSubscription |
( |
| ) |
|
IL_Init
- Parameters
-
Definition at line 78 of file ilMembershipTest.php.
References ilCourseParticipants\_getInstanceByObjId(), and ilParticipants\_isSubscriber().
80 include_once
'./Services/Membership/classes/class.ilParticipants.php';
81 include_once
'./Modules/Course/classes/class.ilCourseParticipants.php';
84 $part->addSubscriber(111111);
85 $part->updateSubscriptionTime(111111, time());
86 $part->updateSubject(111111,
'hallo');
88 $is = $part->isSubscriber(111111);
89 $this->assertEquals($is,
true);
92 $this->assertEquals($is,
true);
94 $part->deleteSubscriber(111111);
95 $is = $part->isSubscriber(111111);
96 $this->assertEquals($is,
false);
static _isSubscriber($a_obj_id, $a_usr_id)
check if user is subscriber
static _getInstanceByObjId($a_obj_id)
Get singleton instance.
◆ $backupGlobals
ilMembershipTest::$backupGlobals = false |
|
protected |
The documentation for this class was generated from the following file: