ILIAS  trunk Revision v11.0_alpha-1749-g1a06bdef097
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilWaitingListTest Class Reference

Unit tests for tree table. More...

+ Inheritance diagram for ilWaitingListTest:
+ Collaboration diagram for ilWaitingListTest:

Public Member Functions

 testConstruction ()
 

Protected Member Functions

 setUp ()
 
 initDependencies ()
 
 setGlobalVariable (string $name, $value)
 

Protected Attributes

 $backupGlobals = false
 
Container $dic
 

Detailed Description

Unit tests for tree table.

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 29 of file ilWaitingListTest.php.

Member Function Documentation

◆ initDependencies()

ilWaitingListTest::initDependencies ( )
protected

Definition at line 50 of file ilWaitingListTest.php.

References $dic, $GLOBALS, and setGlobalVariable().

Referenced by setUp().

50  : void
51  {
52  $this->dic = new Container();
53  $GLOBALS['DIC'] = $this->dic;
54 
55  $this->setGlobalVariable('ilDB', $this->createMock(ilDBInterface::class));
56  $this->setGlobalVariable('ilAppEventHandler', $this->createMock(ilAppEventHandler::class));
57  }
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:35
$GLOBALS["DIC"]
Definition: wac.php:53
setGlobalVariable(string $name, $value)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setGlobalVariable()

ilWaitingListTest::setGlobalVariable ( string  $name,
  $value 
)
protected

Definition at line 59 of file ilWaitingListTest.php.

References $c, $DIC, and $GLOBALS.

Referenced by initDependencies().

59  : void
60  {
61  global $DIC;
62 
63  $GLOBALS[$name] = $value;
64  unset($DIC[$name]);
65  $DIC[$name] = static function (\ILIAS\DI\Container $c) use ($value) {
66  return $value;
67  };
68  }
$c
Definition: deliver.php:25
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:35
$GLOBALS["DIC"]
Definition: wac.php:53
global $DIC
Definition: shib_login.php:22
+ Here is the caller graph for this function:

◆ setUp()

ilWaitingListTest::setUp ( )
protected

Definition at line 35 of file ilWaitingListTest.php.

References initDependencies().

35  : void
36  {
37  $this->initDependencies();
38  parent::setUp();
39  }
+ Here is the call graph for this function:

◆ testConstruction()

ilWaitingListTest::testConstruction ( )

Definition at line 41 of file ilWaitingListTest.php.

41  : void
42  {
43  $obj_id = 0;
44  $some_waiting_list = new class ($obj_id) extends ilWaitingList {
45  };
46  $instance = new $some_waiting_list($obj_id);
47  $this->assertInstanceOf(ilWaitingList::class, $instance);
48  }
Base class for course and group waiting lists.

Field Documentation

◆ $backupGlobals

ilWaitingListTest::$backupGlobals = false
protected

Definition at line 31 of file ilWaitingListTest.php.

◆ $dic

Container ilWaitingListTest::$dic
protected

Definition at line 33 of file ilWaitingListTest.php.

Referenced by initDependencies().


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