Next major version 2 with PHP 8.1, Symfony 6, Tabler UI, 2FA ... (#2902)
This commit is contained in:
30
tests/EventSubscriber/MenuFavoritesSubscriberTest.php
Normal file
30
tests/EventSubscriber/MenuFavoritesSubscriberTest.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of the Kimai time-tracking app.
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace App\Tests\EventSubscriber;
|
||||
|
||||
use App\Event\ConfigureMainMenuEvent;
|
||||
use App\EventSubscriber\MenuFavoritesSubscriber;
|
||||
use App\EventSubscriber\MenuSubscriber;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
/**
|
||||
* @covers \App\EventSubscriber\MenuFavoritesSubscriber
|
||||
*/
|
||||
class MenuFavoritesSubscriberTest extends TestCase
|
||||
{
|
||||
public function testGetSubscribedEvents(): void
|
||||
{
|
||||
$events = MenuFavoritesSubscriber::getSubscribedEvents();
|
||||
$this->assertArrayHasKey(ConfigureMainMenuEvent::class, $events);
|
||||
$methodName = $events[ConfigureMainMenuEvent::class][0];
|
||||
self::assertIsString($methodName);
|
||||
$this->assertTrue(method_exists(MenuSubscriber::class, $methodName));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user