3 declare(strict_types
=1);
5 namespace PhpMyAdmin\Tests\Engines
;
7 use PhpMyAdmin\Dbal\DatabaseInterface
;
8 use PhpMyAdmin\Engines\Bdb
;
9 use PhpMyAdmin\Tests\AbstractTestCase
;
10 use PHPUnit\Framework\Attributes\CoversClass
;
14 #[CoversClass(Bdb::class)]
15 class BdbTest
extends AbstractTestCase
17 protected Bdb
$object;
20 * Sets up the fixture, for example, opens a network connection.
21 * This method is called before a test is executed.
23 protected function setUp(): void
27 DatabaseInterface
::$instance = $this->createDatabaseInterface();
28 $this->object = new Bdb('bdb');
32 * Tears down the fixture, for example, closes a network connection.
33 * This method is called after a test is executed.
35 protected function tearDown(): void
43 * Test for getVariables
45 public function testGetVariables(): void
48 $this->object->getVariables(),
50 'version_bdb' => ['title' => __('Version information')],
51 'bdb_cache_size' => ['type' => 1],
53 'bdb_log_buffer_size' => ['type' => 1],
55 'bdb_max_lock' => ['type' => 2],
56 'bdb_shared_data' => [],
58 'bdb_data_direct' => [],
59 'bdb_lock_detect' => [],
60 'bdb_log_direct' => [],
61 'bdb_no_recover' => [],
63 'skip_sync_bdb_logs' => [],
64 'sync_bdb_logs' => [],
70 * Test for getVariablesLikePattern
72 public function testGetVariablesLikePattern(): void
75 $this->object->getVariablesLikePattern(),
81 * Test for getMysqlHelpPage
83 public function testGetMysqlHelpPage(): void
86 $this->object->getMysqlHelpPage(),