Lines Matching refs:menu
29 $menu = new Menu('Test!');
31 self::assertSame('Test!', $menu->getLabel());
32 self::assertSame('#', $menu->getLink());
33 self::assertSame('', $menu->getClass());
34 self::assertSame([], $menu->getAttrs());
35 self::assertSame([], $menu->getSubmenus());
41 $menu = new Menu('Test!', 'link.html', 'link-class', ['foo' => 'bar'], $submenus);
43 self::assertSame('Test!', $menu->getLabel());
44 self::assertSame('link.html', $menu->getLink());
45 self::assertSame('link-class', $menu->getClass());
46 self::assertSame(['foo' => 'bar'], $menu->getAttrs());
47 self::assertSame($submenus, $menu->getSubmenus());
52 $menu = new Menu('Test!');
54 $return = $menu->setLabel('Label');
56 self::assertSame($return, $menu);
57 self::assertSame('Label', $menu->getLabel());
62 $menu = new Menu('Test!');
64 $return = $menu->setLink('link.html');
66 self::assertSame($return, $menu);
67 self::assertSame('link.html', $menu->getLink());
72 $menu = new Menu('Test!');
74 $return = $menu->setClass('link-class');
76 self::assertSame($return, $menu);
77 self::assertSame('link-class', $menu->getClass());
82 $menu = new Menu('Test!');
84 $return = $menu->setAttrs(['foo' => 'bar']);
86 self::assertSame($return, $menu);
87 self::assertSame(['foo' => 'bar'], $menu->getAttrs());
92 $menu = new Menu('Test!');
98 $return = $menu->setSubmenus($submenus);
100 self::assertSame($return, $menu);
101 self::assertSame($submenus, $menu->getSubmenus());