diff options
author | Michal Čihař <mcihar@suse.cz> | 2012-05-14 18:07:19 +0400 |
---|---|---|
committer | Michal Čihař <mcihar@suse.cz> | 2012-05-14 18:07:19 +0400 |
commit | e96a4379b088069be53a674c64de8e28035b4061 (patch) | |
tree | 3ad5f9d2b721506481e0aeb004353b7354fe5f63 /test | |
parent | 5c466ab97a16ef0082cfc0ad1229e72f5cb03f82 (diff) |
Merge two tests for checkPmaAbsoluteUri
Diffstat (limited to 'test')
-rw-r--r-- | test/classes/PMA_Config_test.php | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/test/classes/PMA_Config_test.php b/test/classes/PMA_Config_test.php index 39dbf91b2b..1314bc9378 100644 --- a/test/classes/PMA_Config_test.php +++ b/test/classes/PMA_Config_test.php @@ -417,7 +417,7 @@ class PMA_ConfigTest extends PHPUnit_Framework_TestCase * @depends testCheckPmaAbsoluteUriEmpty * @dataProvider absoluteUris */ - public function testCheckPmaAbsoluteUriNormal($real, $expected) + public function testCheckPmaAbsoluteUri($real, $expected) { $this->object->set('PmaAbsoluteUri', $real); $this->object->checkPmaAbsoluteUri(); @@ -439,13 +439,21 @@ class PMA_ConfigTest extends PHPUnit_Framework_TestCase 'localhost/phpmyadmin/', 'http://localhost/phpmyadmin/', ), + array( + 'http://user:pwd@localhost/phpmyadmin/index.php', + "http://user:pwd@localhost/phpmyadmin/index.php/", + ), + array( + 'https://user:pwd@localhost/phpmyadmin/index.php', + "https://user:pwd@localhost/phpmyadmin/index.php/", + ), ); } /** + * Test for absolute URI composition * - * - * @depends testCheckPmaAbsoluteUriNormal + * @depends testCheckPmaAbsoluteUri */ public function testCheckPmaAbsoluteUriScheme() { @@ -460,24 +468,6 @@ class PMA_ConfigTest extends PHPUnit_Framework_TestCase $this->assertEquals("http://localhost/", $this->object->get('PmaAbsoluteUri')); } - /** - * - * - * @depends testCheckPmaAbsoluteUriScheme - */ - public function testCheckPmaAbsoluteUriUser() - { - $this->object->set('PmaAbsoluteUri', 'http://user:pwd@localhost/phpmyadmin/index.php'); - - $this->object->checkPmaAbsoluteUri(); - $this->assertEquals("http://user:pwd@localhost/phpmyadmin/index.php/", $this->object->get('PmaAbsoluteUri')); - - $this->object->set('PmaAbsoluteUri', 'https://user:pwd@localhost/phpmyadmin/index.php'); - - $this->object->checkPmaAbsoluteUri(); - $this->assertEquals("https://user:pwd@localhost/phpmyadmin/index.php/", $this->object->get('PmaAbsoluteUri')); - } - public function testCheckCollationConnection() { $_REQUEST['collation_connection'] = 'utf-8'; |