diff options
author | Maurício Meneghini Fauth <mauricio@fauth.dev> | 2021-10-28 19:53:15 +0300 |
---|---|---|
committer | Maurício Meneghini Fauth <mauricio@fauth.dev> | 2021-10-28 19:53:15 +0300 |
commit | 7bcccf7bdcbabacebe366fde5eaa81890f0aff5b (patch) | |
tree | 406b0df7585646eaddb3e402896551d323b8fc6a /test | |
parent | 9dcfc13ac4f0f4a3b8eb4c8050c7c9b9b4205744 (diff) |
Remove connection parameter from getClientInfo
Related to #16911
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
Diffstat (limited to 'test')
-rw-r--r-- | test/classes/Dbal/DbiDummyTest.php | 5 | ||||
-rw-r--r-- | test/classes/Dbal/DbiMysqliTest.php | 9 | ||||
-rw-r--r-- | test/classes/Stubs/DbiDummy.php | 4 |
3 files changed, 4 insertions, 14 deletions
diff --git a/test/classes/Dbal/DbiDummyTest.php b/test/classes/Dbal/DbiDummyTest.php index 26f1215c9e..14c151c7c8 100644 --- a/test/classes/Dbal/DbiDummyTest.php +++ b/test/classes/Dbal/DbiDummyTest.php @@ -33,10 +33,9 @@ class DbiDummyTest extends AbstractTestCase public function testGetClientInfo(): void { - $obj = (object) []; - $this->assertNotEmpty($this->object->getClientInfo($obj)); + $this->assertNotEmpty($this->object->getClientInfo()); // Call the DatabaseInterface - $this->assertSame($GLOBALS['dbi']->getClientInfo(), $this->object->getClientInfo($obj)); + $this->assertSame($GLOBALS['dbi']->getClientInfo(), $this->object->getClientInfo()); } /** diff --git a/test/classes/Dbal/DbiMysqliTest.php b/test/classes/Dbal/DbiMysqliTest.php index 22c34c4f10..282c4c706a 100644 --- a/test/classes/Dbal/DbiMysqliTest.php +++ b/test/classes/Dbal/DbiMysqliTest.php @@ -11,7 +11,6 @@ use PhpMyAdmin\Tests\AbstractTestCase; use const MYSQLI_ASSOC; use const MYSQLI_BOTH; use const MYSQLI_NUM; -use const PHP_VERSION_ID; class DbiMysqliTest extends AbstractTestCase { @@ -32,13 +31,7 @@ class DbiMysqliTest extends AbstractTestCase public function testGetClientInfo(): void { - if (PHP_VERSION_ID < 80100) { - $this->markTestSkipped('This test requires PHP 8.1'); - } - - /** @var mysqli $obj */ - $obj = null; - $this->assertNotEmpty($this->object->getClientInfo($obj)); + $this->assertNotEmpty($this->object->getClientInfo()); } /** diff --git a/test/classes/Stubs/DbiDummy.php b/test/classes/Stubs/DbiDummy.php index bf54f23a54..7cf8c64dea 100644 --- a/test/classes/Stubs/DbiDummy.php +++ b/test/classes/Stubs/DbiDummy.php @@ -354,11 +354,9 @@ class DbiDummy implements DbiExtension /** * returns a string that represents the client library version * - * @param object $link connection link - * * @return string MySQL client library version */ - public function getClientInfo($link) + public function getClientInfo() { return 'libmysql - mysqlnd x.x.x-dev (phpMyAdmin tests)'; } |