Class FactoryImplTest.
More...
◆ setUp()
ILIAS\GlobalScreen\MainMenu\FactoryImplTest::setUp |
( |
| ) |
|
|
protected |
@inheritDoc
Definition at line 49 of file FactoryImplTest.php.
49 : void
50 {
51 parent::setUp();
52
53 $this->identification = new IdentificationFactory(new NullProviderFactory());
54 $this->provider = $this->getMockBuilder(StaticMainMenuProvider::class)->getMock();
55
56 $this->id = $this->identification->core($this->provider)->identifier('dummy');
57
58 $this->
factory =
new MainMenuItemFactory();
59 }
References factory().
◆ testAvailableMethods()
ILIAS\GlobalScreen\MainMenu\FactoryImplTest::testAvailableMethods |
( |
| ) |
|
Definition at line 62 of file FactoryImplTest.php.
62 : void
63 {
64 $r =
new ReflectionClass($this->
factory);
65
66 $methods = [];
67 foreach ($r->getMethods(ReflectionMethod::IS_PUBLIC) as $method) {
68 $methods[] = $method->getName();
69 }
71 $this->assertSame(
72 [
73 0 => 'complex',
74 1 => 'custom',
75 2 => 'link',
76 3 => 'linkList',
77 4 => 'repositoryLink',
78 5 => 'separator',
79 6 => 'topLinkItem',
80 7 => 'topParentItem',
81 ],
82 $methods
83 );
84 }
References factory(), and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().
◆ testInterchangeableContraints()
ILIAS\GlobalScreen\MainMenu\FactoryImplTest::testInterchangeableContraints |
( |
| ) |
|
Definition at line 87 of file FactoryImplTest.php.
87 : void
88 {
89 $this->assertInstanceOf(isInterchangeableItem::class, $this->
factory->topLinkItem($this->id));
90 $this->assertNotInstanceOf(isInterchangeableItem::class, $this->
factory->topParentItem($this->id));
91 $this->assertInstanceOf(isInterchangeableItem::class, $this->
factory->complex($this->id));
92 $this->assertInstanceOf(isInterchangeableItem::class, $this->
factory->link($this->id));
93 $this->assertInstanceOf(isInterchangeableItem::class, $this->
factory->repositoryLink($this->id));
94 $this->assertNotInstanceOf(isInterchangeableItem::class, $this->
factory->separator($this->id));
95 }
References factory().
◆ $factory
◆ $id
◆ $identification
◆ $provider
The documentation for this class was generated from the following file: