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

Class ilTestPlayerConfirmationModalTest. More...

+ Inheritance diagram for ilTestPlayerConfirmationModalTest:
+ Collaboration diagram for ilTestPlayerConfirmationModalTest:

Public Member Functions

 test_instantiateObject_shouldReturnInstance ()
 
 testModalId ()
 
 testHeaderText ()
 
 testConfirmationText ()
 
 testConfirmationCheckboxName ()
 
 testConfirmationCheckboxLabel ()
 
 testAddParameter ()
 
 testIsConfirmationCheckboxRequired ()
 

Protected Member Functions

 setUp ()
 
- Protected Member Functions inherited from ilTestBaseTestCase
 setUp ()
 
 tearDown ()
 
 setGlobalVariable (string $name, $value)
 
 getGlobalTemplateMock ()
 
 getDatabaseMock ()
 
 getIliasMock ()
 
 addGlobal_ilAccess ()
 
 addGlobal_ilUser ()
 
 addGlobal_objDefinition ()
 
 addGlobal_tree ()
 
 addGlobal_ilSetting ()
 
 addGlobal_rbacsystem ()
 
 addGlobal_ilRbacAdmin ()
 
 addGlobal_ilCtrl ()
 
 addGlobal_lng ()
 
 addGlobal_filesystem ()
 
 addGlobal_upload ()
 
 addGlobal_ilDB ()
 
 addGlobal_ilBench ()
 
 addGlobal_ilLog ()
 
 addGlobal_ilias ()
 
 addGlobal_ilErr ()
 
 addGlobal_GlobalScreenService ()
 
 addGlobal_ilNavigationHistory ()
 
 addGlobal_ilAppEventHandler ()
 
 addGlobal_tpl ()
 
 addGlobal_ilComponentRepository ()
 
 addGlobal_ilComponentFactory ()
 
 addGlobal_ilTabs ()
 
 addGlobal_ilObjDataCache ()
 
 addGlobal_ilLocator ()
 
 addGlobal_rbacreview ()
 
 addGlobal_ilToolbar ()
 
 addGlobal_http ()
 
 addGlobal_ilIliasIniFile ()
 
 addGlobal_ilLoggerFactory ()
 
 addGlobal_ilHelp ()
 
 addGlobal_ui ()
 
 addGlobal_uiFactory ()
 
 addGlobal_uiRenderer ()
 
 addGlobal_refinery ()
 
 addGlobal_skillService ()
 
 addGlobal_objectService ()
 
 addGlobal_resourceStorage ()
 
 getTestObjMock ()
 

Private Attributes

ilTestPlayerConfirmationModal $testObj
 

Additional Inherited Members

- Protected Attributes inherited from ilTestBaseTestCase
Container $dic = null
 

Detailed Description

Member Function Documentation

◆ setUp()

ilTestPlayerConfirmationModalTest::setUp ( )
protected

Definition at line 29 of file ilTestPlayerConfirmationModalTest.php.

References $DIC.

29  : void
30  {
31  global $DIC;
32  parent::setUp();
33 
34  $this->testObj = new ilTestPlayerConfirmationModal($DIC['ui.renderer']);
35  }
global $DIC
Definition: feed.php:28

◆ test_instantiateObject_shouldReturnInstance()

ilTestPlayerConfirmationModalTest::test_instantiateObject_shouldReturnInstance ( )

Definition at line 37 of file ilTestPlayerConfirmationModalTest.php.

37  : void
38  {
39  $this->assertInstanceOf(ilTestPlayerConfirmationModal::class, $this->testObj);
40  }

◆ testAddParameter()

ilTestPlayerConfirmationModalTest::testAddParameter ( )

Definition at line 72 of file ilTestPlayerConfirmationModalTest.php.

References $id, ilTestBaseTestCase\addGlobal_ilCtrl(), and ilTestBaseTestCase\addGlobal_lng().

72  : void
73  {
74  $this->addGlobal_ilCtrl();
75 
76  $this->addGlobal_lng();
77  $expected = [];
78 
79  foreach ([51, 291, 15, 681] as $id) {
80  $hiddenInput = new ilHiddenInputGUI("postVar" . "_" . $id);
81  $expected[] = $hiddenInput;
82  }
83 
84  foreach ($expected as $hiddenInput) {
85  $this->testObj->addParameter($hiddenInput);
86  }
87 
88  $this->assertEquals($expected, $this->testObj->getParameters());
89  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
+ Here is the call graph for this function:

◆ testConfirmationCheckboxLabel()

ilTestPlayerConfirmationModalTest::testConfirmationCheckboxLabel ( )

Definition at line 66 of file ilTestPlayerConfirmationModalTest.php.

66  : void
67  {
68  $this->testObj->setConfirmationCheckboxLabel("testString");
69  $this->assertEquals("testString", $this->testObj->getConfirmationCheckboxLabel());
70  }

◆ testConfirmationCheckboxName()

ilTestPlayerConfirmationModalTest::testConfirmationCheckboxName ( )

Definition at line 60 of file ilTestPlayerConfirmationModalTest.php.

60  : void
61  {
62  $this->testObj->setConfirmationCheckboxName("testString");
63  $this->assertEquals("testString", $this->testObj->getConfirmationCheckboxName());
64  }

◆ testConfirmationText()

ilTestPlayerConfirmationModalTest::testConfirmationText ( )

Definition at line 54 of file ilTestPlayerConfirmationModalTest.php.

54  : void
55  {
56  $this->testObj->setConfirmationText("testString");
57  $this->assertEquals("testString", $this->testObj->getConfirmationText());
58  }

◆ testHeaderText()

ilTestPlayerConfirmationModalTest::testHeaderText ( )

Definition at line 48 of file ilTestPlayerConfirmationModalTest.php.

48  : void
49  {
50  $this->testObj->setHeaderText("testString");
51  $this->assertEquals("testString", $this->testObj->getHeaderText());
52  }

◆ testIsConfirmationCheckboxRequired()

ilTestPlayerConfirmationModalTest::testIsConfirmationCheckboxRequired ( )

Definition at line 91 of file ilTestPlayerConfirmationModalTest.php.

91  : void
92  {
93  $this->assertFalse($this->testObj->isConfirmationCheckboxRequired());
94 
95  $this->testObj->setConfirmationCheckboxName("testName");
96  $this->testObj->setConfirmationCheckboxLabel("testLabel");
97  $this->assertTrue($this->testObj->isConfirmationCheckboxRequired());
98  }

◆ testModalId()

ilTestPlayerConfirmationModalTest::testModalId ( )

Definition at line 42 of file ilTestPlayerConfirmationModalTest.php.

42  : void
43  {
44  $this->testObj->setModalId("12345");
45  $this->assertEquals("12345", $this->testObj->getModalId());
46  }

Field Documentation

◆ $testObj

ilTestPlayerConfirmationModal ilTestPlayerConfirmationModalTest::$testObj
private

Definition at line 27 of file ilTestPlayerConfirmationModalTest.php.


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