Test items groups.
More...
Test items groups.
Definition at line 30 of file ItemGroupTest.php.
◆ getFactory()
ItemGroupTest::getFactory |
( |
| ) |
|
◆ testGetItems()
ItemGroupTest::testGetItems |
( |
| ) |
|
◆ testGetTitle()
ItemGroupTest::testGetTitle |
( |
| ) |
|
◆ testImplementsFactoryInterface()
ItemGroupTest::testImplementsFactoryInterface |
( |
| ) |
|
◆ testRenderBase()
ItemGroupTest::testRenderBase |
( |
| ) |
|
Definition at line 92 of file ItemGroupTest.php.
References $c, Vendor\Package\$f, $r, and getFactory().
95 $r = $this->getDefaultRenderer();
98 $f->standard(
"title1"),
99 $f->standard(
"title2")
102 $c =
$f->group(
"group", $items);
104 $html =
$r->render($c);
107 <div
class=
"il-item-group">
109 <div
class=
"il-item-group-items">
112 <li
class=
"il-std-item-container">
113 <div
class=
"il-item il-std-item ">
114 <h4
class=
"il-item-title">title1</h4>
117 <li
class=
"il-std-item-container">
118 <div
class=
"il-item il-std-item ">
119 <h4
class=
"il-item-title">title2</h4>
126 $this->assertHTMLEquals(
127 $this->brutallyTrimHTML($expected),
128 $this->brutallyTrimHTML($html)
◆ testRenderWithActions()
ItemGroupTest::testRenderWithActions |
( |
| ) |
|
Definition at line 132 of file ItemGroupTest.php.
References $c, Vendor\Package\$f, $r, ILIAS\Repository\button(), and getFactory().
135 $r = $this->getDefaultRenderer();
137 $actions =
new I\Component\Dropdown\Standard(array(
142 $f->standard(
"title1"),
143 $f->standard(
"title2")
146 $c =
$f->group(
"group", $items)->withActions($actions);
148 $html =
$r->render($c);
151 <div
class=
"il-item-group">
153 <div
class=
"dropdown" id=
"id_3">
154 <
button class=
"btn btn-default dropdown-toggle" type=
"button" aria-label=
"actions" aria-haspopup=
"true" aria-expanded=
"false" aria-controls=
"id_3_menu">
155 <span
class=
"caret"></span>
157 <ul
id=
"id_3_menu" class=
"dropdown-menu">
159 <
button class=
"btn btn-link" data-action=
"https://www.ilias.de" id=
"id_1">
ILIAS</button>
162 <button
class=
"btn btn-link" data-action=
"https://www.github.com" id=
"id_2">GitHub</button>
166 <div
class=
"il-item-group-items">
168 <li
class=
"il-std-item-container">
169 <div
class=
"il-item il-std-item ">
170 <h4
class=
"il-item-title">title1</h4>
173 <li
class=
"il-std-item-container">
174 <div
class=
"il-item il-std-item ">
175 <h4
class=
"il-item-title">title2</h4>
182 $this->assertHTMLEquals(
183 $this->brutallyTrimHTML($expected),
184 $this->brutallyTrimHTML($html)
button(string $caption, string $cmd)
Interface Observer Contains several chained tasks and infos about them.
◆ testWithActions()
ItemGroupTest::testWithActions |
( |
| ) |
|
Definition at line 74 of file ItemGroupTest.php.
References $c, Vendor\Package\$f, and getFactory().
78 $actions =
new I\Component\Dropdown\Standard(array(
83 $f->standard(
"title1"),
84 $f->standard(
"title2")
87 $c =
$f->group(
"group", $items)->withActions($actions);
89 $this->assertEquals($c->getActions(), $actions);
The documentation for this class was generated from the following file: