ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ComponentRendererLoaderHelperTest.php
Go to the documentation of this file.
1<?php
2
3/* Copyright (c) 2017 Richard Klees <richard.klees@concepts-and-training.de> Extended GPL, see docs/LICENSE */
4
5use PHPUnit\Framework\TestCase;
6
7require_once(__DIR__ . "/TestComponent.php");
8
10{
11 use \ILIAS\UI\Implementation\Render\LoaderHelper;
12
13 public function test_getContextNames()
14 {
15 $c1 = new \ILIAS\UI\Component\Test\TestComponent("foo");
16 $c2 = new \ILIAS\UI\Implementation\Component\Symbol\Glyph\Glyph("up", "up");
17 $names = $this->getContextNames([$c1, $c2]);
18 $expected = ["TestComponentTest", "GlyphGlyphSymbol"];
19 $this->assertEquals($expected, $names);
20 }
21}
An exception for terminatinating execution or to throw for unit testing.