19 declare(strict_types=1);
21 require_once(__DIR__ .
"/../../../../libs/composer/vendor/autoload.php");
22 require_once(__DIR__ .
"/../../Base.php");
36 $this->createMock(
C\Modal\InterruptiveItem\Factory::class),
37 $this->createMock(FieldFactory::class),
40 protected C\Modal\InterruptiveItem\
Factory $item_factory,
45 public function modal(): C\Modal\Factory
47 return new I\Component\Modal\Factory(
53 public function button(): C\Button\Factory
55 return new I\Component\Button\Factory();
62 return new I\Component\Player\Factory();
69 $audio =
$f->audio(
"/foo",
"bar");
71 $this->assertInstanceOf(
"ILIAS\\UI\\Component\\Player\\Audio", $audio);
78 $audio =
$f->audio(
"/foo");
80 $this->assertEquals(
"/foo", $audio->getSource());
87 $audio =
$f->audio(
"/foo",
"bar");
89 $this->assertEquals(
"bar", $audio->getTranscription());
97 $audio =
$f->audio(
"/foo");
99 $html =
$r->render($audio);
102 <div
class=
"il-audio-container">
103 <audio
class=
"il-audio-player" id=
"id_1" src=
"/foo" preload=
"metadata"></audio>
117 $audio =
$f->audio(
"/foo",
"x*123");
119 $html =
$r->render($audio);
123 is_int(strpos($html,
"ui_transcription</button>"))
127 is_int(strpos($html,
"il-modal-lightbox"))
131 is_int(strpos($html,
"x*123"))
getDefaultRenderer(JavaScriptBinding $js_binding=null, array $with_stub_renderings=[])
button(string $caption, string $cmd)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
testRenderWithTranscript()
testImplementsFactoryInterface()
testGetTitleGetTranscript()
brutallyTrimHTML(string $html)
A more radical version of normalizeHTML.
assertHTMLEquals(string $expected_html_as_string, string $html_as_string)
Provides common functionality for UI tests.
modal(string $title="", string $cancel_label="")