39 lines
858 B
PHP
39 lines
858 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace PhpMyAdmin\Tests\Navigation\Nodes;
|
|
|
|
use PhpMyAdmin\Navigation\NodeFactory;
|
|
use PhpMyAdmin\Tests\AbstractTestCase;
|
|
|
|
class NodeIndexContainerTest extends AbstractTestCase
|
|
{
|
|
/**
|
|
* SetUp for test cases
|
|
*/
|
|
protected function setUp(): void
|
|
{
|
|
parent::setUp();
|
|
parent::loadDefaultConfig();
|
|
$GLOBALS['server'] = 0;
|
|
}
|
|
|
|
/**
|
|
* Test for __construct
|
|
*/
|
|
public function testConstructor(): void
|
|
{
|
|
$parent = NodeFactory::getInstance('NodeIndexContainer');
|
|
$this->assertArrayHasKey(
|
|
'text',
|
|
$parent->links
|
|
);
|
|
$this->assertStringContainsString(
|
|
'index.php?route=/table/structure',
|
|
$parent->links['text']
|
|
);
|
|
$this->assertEquals('indexes', $parent->realName);
|
|
}
|
|
}
|