ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilTestRandomQuestionSetConfigStateMessageHandlerTest Class Reference

Class ilTestRandomQuestionSetConfigStateMessageHandlerTest. More...

+ Inheritance diagram for ilTestRandomQuestionSetConfigStateMessageHandlerTest:
+ Collaboration diagram for ilTestRandomQuestionSetConfigStateMessageHandlerTest:

Public Member Functions

 test_instantiateObject_shouldReturnInstance ()
 
 testLostPools ()
 
 testParticipantDataExists ()
 
 testTargetGUI ()
 
 testContext ()
 
 testQuestionSetConfig ()
 
- Public Member Functions inherited from ilTestBaseTestCase
 createInstanceOf (string $class_name, array $explicit_parameters=[])
 
 createTraitInstanceOf (string $class_name, array $explicit_parameters=[])
 

Protected Member Functions

 setUp ()
 
- Protected Member Functions inherited from ilTestBaseTestCase
 setUp ()
 
 tearDown ()
 

Private Attributes

ilTestRandomQuestionSetConfigStateMessageHandler $testObj
 

Additional Inherited Members

- Static Public Member Functions inherited from ilTestBaseTestCase
static callMethod ($obj, $name, array $args=[])
 
static getNonPublicPropertyValue (object $obj, string $name)
 
- Data Fields inherited from ilTestBaseTestCase
const string MOCKED_METHOD_WITHOUT_OUTPUT = 'MOCKED_METHOD_WITHOUT_OUTPUT'
 
const string DYNAMIC_CLASS = 'DynamicClass'
 
- Protected Attributes inherited from ilTestBaseTestCase
Container $dic = null
 
Container $backup_dic = null
 
- Static Protected Attributes inherited from ilTestBaseTestCase
static int $DYNAMIC_CLASS_COUNT = 0
 

Detailed Description

Member Function Documentation

◆ setUp()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::setUp ( )
protected

Reimplemented from ilTestBaseTestCase.

Definition at line 29 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

29 : void
30 {
31 global $DIC;
32 parent::setUp();
33
35 $DIC['lng'],
36 $DIC['ui.factory'],
37 $DIC['ui.renderer'],
38 $DIC['ilCtrl']
39 );
40 }
global $DIC
Definition: shib_login.php:26

References $DIC.

◆ test_instantiateObject_shouldReturnInstance()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::test_instantiateObject_shouldReturnInstance ( )

Definition at line 42 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

42 : void
43 {
44 $this->assertInstanceOf(ilTestRandomQuestionSetConfigStateMessageHandler::class, $this->testObj);
45 }

◆ testContext()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::testContext ( )

Definition at line 75 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

75 : void
76 {
77 $context = 'test';
78 $this->testObj->setContext($context);
79 $this->assertEquals($context, $this->testObj->getContext());
80 }
$context
Definition: webdav.php:31

References $context.

◆ testLostPools()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::testLostPools ( )

Definition at line 47 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

47 : void
48 {
49 $expected = [
53 ];
54
55 $this->testObj->setLostPools($expected);
56 $this->assertEquals($expected, $this->testObj->getLostPools());
57 }

◆ testParticipantDataExists()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::testParticipantDataExists ( )

Definition at line 59 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

59 : void
60 {
61 $this->testObj->setParticipantDataExists(false);
62 $this->assertFalse($this->testObj->doesParticipantDataExists());
63
64 $this->testObj->setParticipantDataExists(true);
65 $this->assertTrue($this->testObj->doesParticipantDataExists());
66 }

◆ testQuestionSetConfig()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::testQuestionSetConfig ( )

Definition at line 82 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

82 : void
83 {
84 $mock = $this->createMock(ilTestRandomQuestionSetConfig::class);
85 $this->testObj->setQuestionSetConfig($mock);
86 $this->assertEquals($mock, $this->testObj->getQuestionSetConfig());
87 }

◆ testTargetGUI()

ilTestRandomQuestionSetConfigStateMessageHandlerTest::testTargetGUI ( )

Definition at line 68 of file ilTestRandomQuestionSetConfigStateMessageHandlerTest.php.

68 : void
69 {
70 $targetGui_mock = $this->createMock(ilTestRandomQuestionSetConfigGUI::class);
71 $this->testObj->setTargetGUI($targetGui_mock);
72 $this->assertEquals($targetGui_mock, $this->testObj->getTargetGUI());
73 }

Field Documentation

◆ $testObj

ilTestRandomQuestionSetConfigStateMessageHandler ilTestRandomQuestionSetConfigStateMessageHandlerTest::$testObj
private

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