ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilSystemStyleDocumentationGUITest Class Reference
+ Inheritance diagram for ilSystemStyleDocumentationGUITest:
+ Collaboration diagram for ilSystemStyleDocumentationGUITest:

Public Member Functions

 testConstruct ()
 
 testShow ()
 

Protected Member Functions

 setUp ()
 

Protected Attributes

ilSystemStyleDocumentationGUI $documentation_gui
 
ilGlobalPageTemplate $tpl_observer
 

Detailed Description

Definition at line 27 of file ilSystemStyleDocumentationGUITest.php.

Member Function Documentation

◆ setUp()

ilSystemStyleDocumentationGUITest::setUp ( )
protected

Definition at line 32 of file ilSystemStyleDocumentationGUITest.php.

32  : void
33  {
34  $ui_helper = new UITestHelper();
35  $this->tpl_observer = $this->getMockBuilder(ilGlobalPageTemplate::class)->disableOriginalConstructor()->getMock();
36  $ctrl = $this->getMockBuilder(ilCtrl::class)->disableOriginalConstructor()->getMock();
37 
38  $this->documentation_gui = new ilSystemStyleDocumentationGUI(
39  $this->tpl_observer,
40  $ctrl,
41  $ui_helper->factory(),
42  $ui_helper->renderer()
43  );
44  }
Renders the Overview of the Examples in the Administration.
Class UITestHelper can be helpful for test cases outside the UI Components, to inject a working facto...

◆ testConstruct()

ilSystemStyleDocumentationGUITest::testConstruct ( )

Definition at line 46 of file ilSystemStyleDocumentationGUITest.php.

46  : void
47  {
48  $this->assertInstanceOf(ilSystemStyleDocumentationGUI::class, $this->documentation_gui);
49  }

◆ testShow()

ilSystemStyleDocumentationGUITest::testShow ( )

Definition at line 51 of file ilSystemStyleDocumentationGUITest.php.

51  : void
52  {
53  $entries_data = include './tests/UI/Crawler/Fixture/EntriesFixture.php';
54  $entries = new Entries();
55  $entries->addEntriesFromArray($entries_data);
56  $this->tpl_observer->expects($this->once())
57  ->method('setContent')
58  ->with($this->stringContains('Entry1Title'));
59  $this->documentation_gui->show($entries, 'Entry1');
60  }

Field Documentation

◆ $documentation_gui

ilSystemStyleDocumentationGUI ilSystemStyleDocumentationGUITest::$documentation_gui
protected

Definition at line 29 of file ilSystemStyleDocumentationGUITest.php.

◆ $tpl_observer

ilGlobalPageTemplate ilSystemStyleDocumentationGUITest::$tpl_observer
protected

Definition at line 30 of file ilSystemStyleDocumentationGUITest.php.


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