phpmyadmin/tests/unit/Navigation/Nodes/NodeIndexTest.php
Maurício Meneghini Fauth 606f66b5df
Rename tests/classes to tests/unit
This directory is for unit tests only, so let's rename it to unit to be
more clear.

Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
2024-02-23 13:29:07 -03:00

30 lines
803 B
PHP

<?php
declare(strict_types=1);
namespace PhpMyAdmin\Tests\Navigation\Nodes;
use PhpMyAdmin\Config;
use PhpMyAdmin\Navigation\Nodes\NodeIndex;
use PhpMyAdmin\Tests\AbstractTestCase;
use PHPUnit\Framework\Attributes\CoversClass;
#[CoversClass(NodeIndex::class)]
class NodeIndexTest extends AbstractTestCase
{
/**
* Test for __construct
*/
public function testConstructor(): void
{
$parent = new NodeIndex(new Config(), 'default');
self::assertSame(
[
'text' => ['route' => '/table/indexes', 'params' => ['db' => null, 'table' => null, 'index' => null]],
'icon' => ['route' => '/table/indexes', 'params' => ['db' => null, 'table' => null, 'index' => null]],
],
$parent->links,
);
}
}