ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ModalBase.php
Go to the documentation of this file.
1 <?php
2 require_once(__DIR__ . "/../../../../libs/composer/vendor/autoload.php");
3 require_once(__DIR__ . "/../../Base.php");
4 
5 use \ILIAS\UI\Component as C;
6 
12 abstract class ModalBase extends ILIAS_UI_TestBase
13 {
14  public function getUIFactory()
15  {
16  return new \ILIAS\UI\Implementation\Factory();
17  }
18 
19  protected function getModalFactory()
20  {
21  return new \ILIAS\UI\Implementation\Component\Modal\Factory(new SignalGeneratorMock());
22  }
23 
24  protected function getButtonFactory()
25  {
26  return new \ILIAS\UI\Implementation\Component\Button\Factory();
27  }
28 
29  protected function getDummyComponent()
30  {
31  return new DummyComponent();
32  }
33 
34  public function normalizeHTML($html)
35  {
36  $html = parent::normalizeHTML($html);
37  // The times entity is used for closing the modal and not supported in DomDocument::loadXML()
38  return str_replace(['&times;', "\t"], ['', ''], $html);
39  }
40 }
getButtonFactory()
Definition: ModalBase.php:24
getUIFactory()
Definition: ModalBase.php:14
getDummyComponent()
Definition: ModalBase.php:29
normalizeHTML($html)
Definition: ModalBase.php:34
Provides common functionality for UI tests.
Definition: Base.php:177
Base class for modal tests.
Definition: ModalBase.php:12
getModalFactory()
Definition: ModalBase.php:19
$html
Definition: example_001.php:87