ILIAS  trunk Revision v11.0_alpha-1769-g99a433fe2dc
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
assSingleChoiceGUITest Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for assSingleChoiceGUITest:
+ Collaboration diagram for assSingleChoiceGUITest:

Public Member Functions

 test_instantiateObject_shouldReturnInstance ()
 

Protected Member Functions

 setUp ()
 
- Protected Member Functions inherited from assBaseTestCase
 setUp ()
 
 tearDown ()
 
 getIRSSMock ()
 

Protected Attributes

 $backupGlobals = false
 
- Protected Attributes inherited from assBaseTestCase
Container $dic = null
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Unit tests for single choice questions

Author
Helmut Schottmüller ilias.nosp@m.@aur.nosp@m.ealis.nosp@m..de
Version
Id
assSingleChoiceTest.php 35946 2012-08-02 21:48:44Z mbecker

Definition at line 28 of file assSingleChoiceGUITest.php.

Member Function Documentation

◆ setUp()

assSingleChoiceGUITest::setUp ( )
protected

Definition at line 32 of file assSingleChoiceGUITest.php.

32  : void
33  {
34  parent::setUp();
35 
36  $this->setGlobalVariable('ilLog', $this->createMock(ilLogger::class));
37 
38  $ilCtrl_mock = $this->getMockBuilder(ilCtrl::class)
39  ->disableOriginalConstructor()
40  ->getMock();
41  $ilCtrl_mock->method('saveParameter');
42  $ilCtrl_mock->method('saveParameterByClass');
43  $this->setGlobalVariable('ilCtrl', $ilCtrl_mock);
44 
45  $lng_mock = $this->getMockBuilder(ilLanguage::class)
46  ->disableOriginalConstructor()
47  ->onlyMethods(['txt'])
48  ->getMock();
49  $lng_mock->method('txt')->will($this->returnValue('Test'));
50  $this->setGlobalVariable('lng', $lng_mock);
51 
52  $this->setGlobalVariable('ilias', $this->getIliasMock());
53  $this->setGlobalVariable('ilDB', $this->getDatabaseMock());
54  }

◆ test_instantiateObject_shouldReturnInstance()

assSingleChoiceGUITest::test_instantiateObject_shouldReturnInstance ( )

Definition at line 56 of file assSingleChoiceGUITest.php.

56  : void
57  {
58  $instance = new assSingleChoiceGUI();
59 
60  $this->assertInstanceOf(assSingleChoiceGUI::class, $instance);
61  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

Field Documentation

◆ $backupGlobals

assSingleChoiceGUITest::$backupGlobals = false
protected

Definition at line 30 of file assSingleChoiceGUITest.php.


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