From 3ef8c95b3790e6e9be94f772b65e4aa19c042d50 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Thu, 12 May 2016 17:14:59 +0200 Subject: [PATCH] Move tests/ to PSR-4 --- apps/user_ldap/tests/{access.php => AccessTest.php} | 8 ++++---- .../{configuration.php => ConfigurationTest.php} | 4 ++-- .../tests/{connection.php => ConnectionTest.php} | 6 +++--- .../tests/{GroupLDAPTest.php => Group_LDAPTest.php} | 4 ++-- .../AbstractIntegrationTest.php} | 2 +- .../ExceptionOnLostConnection.php} | 3 +++ .../fakemanager.php => Integration/FakeManager.php} | 2 +- .../Lib}/IntegrationTestAccessGroupsMatchFilter.php | 6 +++--- .../Lib/IntegrationTestBackupServer.php} | 6 +++--- .../IntegrationTestBatchApplyUserAttributes.php} | 4 ++-- .../Lib/IntegrationTestConnect.php} | 7 +++---- .../Lib/IntegrationTestCountUsersByLoginName.php} | 9 +++------ .../Lib/IntegrationTestFetchUsersByLoginName.php} | 7 +++---- .../Lib/IntegrationTestPaging.php} | 5 ++--- .../Lib/IntegrationTestUserHome.php} | 4 ++-- .../Lib/User}/IntegrationTestUserAvatar.php | 6 ++++-- .../Lib/User}/IntegrationTestUserDisplayName.php | 7 ++++--- .../data/avatar-invalid.gif | Bin .../data/avatar-valid.jpg | Bin .../tests/{integration => Integration}/readme.md | 0 .../tests/{integration => Integration}/run-test.sh | 0 .../setup-scripts/createExplicitGroups.php | 0 .../createExplicitGroupsDifferentOU.php | 0 .../setup-scripts/createExplicitUsers.php | 0 .../setup-scripts/createUsersWithoutDisplayName.php | 0 .../{jobs/cleanup.php => Jobs/CleanUpTest.php} | 4 ++-- .../AbstractMappingTest.php} | 2 +- .../GroupMappingTest.php} | 8 ++++---- .../usermapping.php => Mapping/UserMappingTest.php} | 8 ++++---- apps/user_ldap/tests/User/ManagerTest.php | 2 +- apps/user_ldap/tests/User/UserTest.php | 4 ++-- apps/user_ldap/tests/WizardTest.php | 9 ++------- 32 files changed, 61 insertions(+), 66 deletions(-) rename apps/user_ldap/tests/{access.php => AccessTest.php} (98%) rename apps/user_ldap/tests/{configuration.php => ConfigurationTest.php} (97%) rename apps/user_ldap/tests/{connection.php => ConnectionTest.php} (97%) rename apps/user_ldap/tests/{GroupLDAPTest.php => Group_LDAPTest.php} (99%) rename apps/user_ldap/tests/{integration/abstractintegrationtest.php => Integration/AbstractIntegrationTest.php} (98%) rename apps/user_ldap/tests/{integration/exceptionOnLostConnection.php => Integration/ExceptionOnLostConnection.php} (99%) rename apps/user_ldap/tests/{integration/fakemanager.php => Integration/FakeManager.php} (96%) rename apps/user_ldap/tests/{integration/lib => Integration/Lib}/IntegrationTestAccessGroupsMatchFilter.php (96%) rename apps/user_ldap/tests/{integration/lib/integrationtestbackupserver.php => Integration/Lib/IntegrationTestBackupServer.php} (94%) rename apps/user_ldap/tests/{integration/lib/integrationtestbatchapplyuserattributes.php => Integration/Lib/IntegrationTestBatchApplyUserAttributes.php} (95%) rename apps/user_ldap/tests/{integration/lib/integrationtestconnect.php => Integration/Lib/IntegrationTestConnect.php} (94%) rename apps/user_ldap/tests/{integration/lib/integrationtestcountusersbyloginname.php => Integration/Lib/IntegrationTestCountUsersByLoginName.php} (85%) rename apps/user_ldap/tests/{integration/lib/integrationtestfetchusersbyloginname.php => Integration/Lib/IntegrationTestFetchUsersByLoginName.php} (90%) rename apps/user_ldap/tests/{integration/lib/integrationtestpaging.php => Integration/Lib/IntegrationTestPaging.php} (92%) rename apps/user_ldap/tests/{integration/lib/integrationtestuserhome.php => Integration/Lib/IntegrationTestUserHome.php} (97%) rename apps/user_ldap/tests/{integration/lib/user => Integration/Lib/User}/IntegrationTestUserAvatar.php (95%) rename apps/user_ldap/tests/{integration/lib/user => Integration/Lib/User}/IntegrationTestUserDisplayName.php (93%) rename apps/user_ldap/tests/{integration => Integration}/data/avatar-invalid.gif (100%) rename apps/user_ldap/tests/{integration => Integration}/data/avatar-valid.jpg (100%) rename apps/user_ldap/tests/{integration => Integration}/readme.md (100%) rename apps/user_ldap/tests/{integration => Integration}/run-test.sh (100%) rename apps/user_ldap/tests/{integration => Integration}/setup-scripts/createExplicitGroups.php (100%) rename apps/user_ldap/tests/{integration => Integration}/setup-scripts/createExplicitGroupsDifferentOU.php (100%) rename apps/user_ldap/tests/{integration => Integration}/setup-scripts/createExplicitUsers.php (100%) rename apps/user_ldap/tests/{integration => Integration}/setup-scripts/createUsersWithoutDisplayName.php (100%) rename apps/user_ldap/tests/{jobs/cleanup.php => Jobs/CleanUpTest.php} (97%) rename apps/user_ldap/tests/{mapping/abstractmappingtest.php => Mapping/AbstractMappingTest.php} (99%) rename apps/user_ldap/tests/{mapping/groupmapping.php => Mapping/GroupMappingTest.php} (86%) rename apps/user_ldap/tests/{mapping/usermapping.php => Mapping/UserMappingTest.php} (86%) diff --git a/apps/user_ldap/tests/access.php b/apps/user_ldap/tests/AccessTest.php similarity index 98% rename from apps/user_ldap/tests/access.php rename to apps/user_ldap/tests/AccessTest.php index b1401b7c9b..97012f8c72 100644 --- a/apps/user_ldap/tests/access.php +++ b/apps/user_ldap/tests/AccessTest.php @@ -23,19 +23,19 @@ * */ -namespace OCA\user_ldap\tests; +namespace OCA\User_LDAP\Tests; use OCA\User_LDAP\Access; use OCA\User_LDAP\Connection; /** - * Class Test_Access + * Class AccessTest * * @group DB * - * @package OCA\user_ldap\tests + * @package OCA\User_LDAP\Tests */ -class Test_Access extends \Test\TestCase { +class AccessTest extends \Test\TestCase { private function getConnectorAndLdapMock() { static $conMethods; static $accMethods; diff --git a/apps/user_ldap/tests/configuration.php b/apps/user_ldap/tests/ConfigurationTest.php similarity index 97% rename from apps/user_ldap/tests/configuration.php rename to apps/user_ldap/tests/ConfigurationTest.php index d4f1ce142b..808a4c9ed0 100644 --- a/apps/user_ldap/tests/configuration.php +++ b/apps/user_ldap/tests/ConfigurationTest.php @@ -19,9 +19,9 @@ * */ -namespace OCA\user_ldap\tests; +namespace OCA\User_LDAP\Tests; -class Test_Configuration extends \Test\TestCase { +class ConfigurationTest extends \Test\TestCase { public function configurationDataProvider() { $inputWithDN = array( diff --git a/apps/user_ldap/tests/connection.php b/apps/user_ldap/tests/ConnectionTest.php similarity index 97% rename from apps/user_ldap/tests/connection.php rename to apps/user_ldap/tests/ConnectionTest.php index 2c87d41cfa..ad0bed240c 100644 --- a/apps/user_ldap/tests/connection.php +++ b/apps/user_ldap/tests/ConnectionTest.php @@ -22,7 +22,7 @@ * */ -namespace OCA\user_ldap\tests; +namespace OCA\User_LDAP\Tests; use OCA\User_LDAP\Connection; /** @@ -30,9 +30,9 @@ use OCA\User_LDAP\Connection; * * @group DB * - * @package OCA\user_ldap\tests + * @package OCA\User_LDAP\Tests */ -class Test_Connection extends \Test\TestCase { +class ConnectionTest extends \Test\TestCase { /** @var \OCA\User_LDAP\ILDAPWrapper */ protected $ldap; diff --git a/apps/user_ldap/tests/GroupLDAPTest.php b/apps/user_ldap/tests/Group_LDAPTest.php similarity index 99% rename from apps/user_ldap/tests/GroupLDAPTest.php rename to apps/user_ldap/tests/Group_LDAPTest.php index 57c22f8bda..bf9f40a1b2 100644 --- a/apps/user_ldap/tests/GroupLDAPTest.php +++ b/apps/user_ldap/tests/Group_LDAPTest.php @@ -35,9 +35,9 @@ use OCA\User_LDAP\Connection; * * @group DB * - * @package OCA\user_ldap\tests + * @package OCA\User_LDAP\Tests */ -class GroupLDAPTest extends \Test\TestCase { +class Group_LDAPTest extends \Test\TestCase { private function getAccessMock() { static $conMethods; static $accMethods; diff --git a/apps/user_ldap/tests/integration/abstractintegrationtest.php b/apps/user_ldap/tests/Integration/AbstractIntegrationTest.php similarity index 98% rename from apps/user_ldap/tests/integration/abstractintegrationtest.php rename to apps/user_ldap/tests/Integration/AbstractIntegrationTest.php index 7b3d7b171c..a736956ebf 100644 --- a/apps/user_ldap/tests/integration/abstractintegrationtest.php +++ b/apps/user_ldap/tests/Integration/AbstractIntegrationTest.php @@ -19,7 +19,7 @@ * */ -namespace OCA\user_ldap\tests\integration; +namespace OCA\User_LDAP\Tests\Integration; use OCA\User_LDAP\Access; use OCA\User_LDAP\Connection; diff --git a/apps/user_ldap/tests/integration/exceptionOnLostConnection.php b/apps/user_ldap/tests/Integration/ExceptionOnLostConnection.php similarity index 99% rename from apps/user_ldap/tests/integration/exceptionOnLostConnection.php rename to apps/user_ldap/tests/Integration/ExceptionOnLostConnection.php index 007c1116d0..fd3edcbf0c 100644 --- a/apps/user_ldap/tests/integration/exceptionOnLostConnection.php +++ b/apps/user_ldap/tests/Integration/ExceptionOnLostConnection.php @@ -19,6 +19,9 @@ * */ +namespace OCA\User_LDAP\Tests\Integration; + + use OC\ServerNotAvailableException; use OCA\User_LDAP\LDAP; diff --git a/apps/user_ldap/tests/integration/fakemanager.php b/apps/user_ldap/tests/Integration/FakeManager.php similarity index 96% rename from apps/user_ldap/tests/integration/fakemanager.php rename to apps/user_ldap/tests/Integration/FakeManager.php index 6d67e98fb4..11f270dba0 100644 --- a/apps/user_ldap/tests/integration/fakemanager.php +++ b/apps/user_ldap/tests/Integration/FakeManager.php @@ -19,7 +19,7 @@ * */ -namespace OCA\user_ldap\tests\integration; +namespace OCA\User_LDAP\Tests\Integration; /** * Class FakeManager diff --git a/apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestAccessGroupsMatchFilter.php similarity index 96% rename from apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestAccessGroupsMatchFilter.php index 829dc2e0a4..d058540bd4 100644 --- a/apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestAccessGroupsMatchFilter.php @@ -19,10 +19,10 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\User_LDAP\Connection; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; + +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; require_once __DIR__ . '/../../../../../lib/base.php'; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestbackupserver.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestBackupServer.php similarity index 94% rename from apps/user_ldap/tests/integration/lib/integrationtestbackupserver.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestBackupServer.php index 450032de9a..ccd9b251bf 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestbackupserver.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestBackupServer.php @@ -19,15 +19,15 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; use OCA\User_LDAP\Mapping\UserMapping; use OCA\User_LDAP\User_LDAP; require_once __DIR__ . '/../../../../../lib/base.php'; -class IntegrationBackupServer extends AbstractIntegrationTest { +class IntegrationTestBackupServer extends AbstractIntegrationTest { /** @var UserMapping */ protected $mapping; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestbatchapplyuserattributes.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestBatchApplyUserAttributes.php similarity index 95% rename from apps/user_ldap/tests/integration/lib/integrationtestbatchapplyuserattributes.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestBatchApplyUserAttributes.php index 587811eb13..89afcaa4b9 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestbatchapplyuserattributes.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestBatchApplyUserAttributes.php @@ -19,10 +19,10 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; use OCA\User_LDAP\Mapping\UserMapping; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; require_once __DIR__ . '/../../../../../lib/base.php'; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestconnect.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestConnect.php similarity index 94% rename from apps/user_ldap/tests/integration/lib/integrationtestconnect.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestConnect.php index e453c52b2c..3ada556bbe 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestconnect.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestConnect.php @@ -19,16 +19,15 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\User_LDAP\User\Manager as LDAPUserManager; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; use OCA\User_LDAP\Mapping\UserMapping; use OCA\User_LDAP\User_LDAP; require_once __DIR__ . '/../../../../../lib/base.php'; -class IntegrationConnect extends AbstractIntegrationTest { +class IntegrationTestConnect extends AbstractIntegrationTest { /** @var UserMapping */ protected $mapping; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestcountusersbyloginname.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestCountUsersByLoginName.php similarity index 85% rename from apps/user_ldap/tests/integration/lib/integrationtestcountusersbyloginname.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestCountUsersByLoginName.php index bf46cfeffa..5f4fd6f572 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestcountusersbyloginname.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestCountUsersByLoginName.php @@ -19,16 +19,13 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\User_LDAP\User\Manager as LDAPUserManager; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; -use OCA\User_LDAP\Mapping\UserMapping; -use OCA\User_LDAP\User_LDAP; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; require_once __DIR__ . '/../../../../../lib/base.php'; -class IntegrationTestUserHome extends AbstractIntegrationTest { +class IntegrationTestCountUsersByLoginName extends AbstractIntegrationTest { /** * prepares the LDAP environment and sets up a test configuration for diff --git a/apps/user_ldap/tests/integration/lib/integrationtestfetchusersbyloginname.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestFetchUsersByLoginName.php similarity index 90% rename from apps/user_ldap/tests/integration/lib/integrationtestfetchusersbyloginname.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestFetchUsersByLoginName.php index 9713f26ba7..f2dbd7393f 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestfetchusersbyloginname.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestFetchUsersByLoginName.php @@ -19,16 +19,15 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\User_LDAP\User\Manager as LDAPUserManager; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; use OCA\User_LDAP\Mapping\UserMapping; use OCA\User_LDAP\User_LDAP; require_once __DIR__ . '/../../../../../lib/base.php'; -class IntegrationTestUserHome extends AbstractIntegrationTest { +class IntegrationTestFetchUsersByLoginName extends AbstractIntegrationTest { /** @var UserMapping */ protected $mapping; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestpaging.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestPaging.php similarity index 92% rename from apps/user_ldap/tests/integration/lib/integrationtestpaging.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestPaging.php index 1de0a4d059..72cc3e459b 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestpaging.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestPaging.php @@ -19,10 +19,9 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; -use OCA\User_LDAP\User\Manager as LDAPUserManager; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; use OCA\User_LDAP\Mapping\UserMapping; use OCA\User_LDAP\User_LDAP; diff --git a/apps/user_ldap/tests/integration/lib/integrationtestuserhome.php b/apps/user_ldap/tests/Integration/Lib/IntegrationTestUserHome.php similarity index 97% rename from apps/user_ldap/tests/integration/lib/integrationtestuserhome.php rename to apps/user_ldap/tests/Integration/Lib/IntegrationTestUserHome.php index 751cb99600..8538fd2f96 100644 --- a/apps/user_ldap/tests/integration/lib/integrationtestuserhome.php +++ b/apps/user_ldap/tests/Integration/Lib/IntegrationTestUserHome.php @@ -19,10 +19,10 @@ * */ -namespace OCA\user_ldap\tests\integration\lib; +namespace OCA\User_LDAP\Tests\Integration\Lib; use OCA\User_LDAP\User\Manager as LDAPUserManager; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; use OCA\User_LDAP\Mapping\UserMapping; use OCA\User_LDAP\User_LDAP; diff --git a/apps/user_ldap/tests/integration/lib/user/IntegrationTestUserAvatar.php b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserAvatar.php similarity index 95% rename from apps/user_ldap/tests/integration/lib/user/IntegrationTestUserAvatar.php rename to apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserAvatar.php index 195862226b..5f555956ea 100644 --- a/apps/user_ldap/tests/integration/lib/user/IntegrationTestUserAvatar.php +++ b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserAvatar.php @@ -21,9 +21,11 @@ * */ +namespace OCA\User_LDAP\Tests\Integration\Lib\User; + use OCA\User_LDAP\User\User; use OCA\User_LDAP\Mapping\UserMapping; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; require_once __DIR__ . '/../../../../../../lib/base.php'; @@ -41,7 +43,7 @@ class IntegrationTestUserAvatar extends AbstractIntegrationTest { $this->mapping = new UserMapping(\OC::$server->getDatabaseConnection()); $this->mapping->clear(); $this->access->setUserMapper($this->mapping); - $userBackend = new OCA\User_LDAP\User_LDAP($this->access, \OC::$server->getConfig()); + $userBackend = new \OCA\User_LDAP\User_LDAP($this->access, \OC::$server->getConfig()); \OC_User::useBackend($userBackend); } diff --git a/apps/user_ldap/tests/integration/lib/user/IntegrationTestUserDisplayName.php b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserDisplayName.php similarity index 93% rename from apps/user_ldap/tests/integration/lib/user/IntegrationTestUserDisplayName.php rename to apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserDisplayName.php index d1c048b4d2..07ab2e287c 100644 --- a/apps/user_ldap/tests/integration/lib/user/IntegrationTestUserDisplayName.php +++ b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserDisplayName.php @@ -19,9 +19,10 @@ * */ -use OCA\User_LDAP\User\User; +namespace OCA\User_LDAP\Tests\Integration\Lib\User; + use OCA\User_LDAP\Mapping\UserMapping; -use OCA\user_ldap\tests\integration\AbstractIntegrationTest; +use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest; require_once __DIR__ . '/../../../../../../lib/base.php'; @@ -39,7 +40,7 @@ class IntegrationTestUserDisplayName extends AbstractIntegrationTest { $this->mapping = new UserMapping(\OC::$server->getDatabaseConnection()); $this->mapping->clear(); $this->access->setUserMapper($this->mapping); - $userBackend = new OCA\User_LDAP\User_LDAP($this->access, \OC::$server->getConfig()); + $userBackend = new \OCA\User_LDAP\User_LDAP($this->access, \OC::$server->getConfig()); \OC_User::useBackend($userBackend); } diff --git a/apps/user_ldap/tests/integration/data/avatar-invalid.gif b/apps/user_ldap/tests/Integration/data/avatar-invalid.gif similarity index 100% rename from apps/user_ldap/tests/integration/data/avatar-invalid.gif rename to apps/user_ldap/tests/Integration/data/avatar-invalid.gif diff --git a/apps/user_ldap/tests/integration/data/avatar-valid.jpg b/apps/user_ldap/tests/Integration/data/avatar-valid.jpg similarity index 100% rename from apps/user_ldap/tests/integration/data/avatar-valid.jpg rename to apps/user_ldap/tests/Integration/data/avatar-valid.jpg diff --git a/apps/user_ldap/tests/integration/readme.md b/apps/user_ldap/tests/Integration/readme.md similarity index 100% rename from apps/user_ldap/tests/integration/readme.md rename to apps/user_ldap/tests/Integration/readme.md diff --git a/apps/user_ldap/tests/integration/run-test.sh b/apps/user_ldap/tests/Integration/run-test.sh similarity index 100% rename from apps/user_ldap/tests/integration/run-test.sh rename to apps/user_ldap/tests/Integration/run-test.sh diff --git a/apps/user_ldap/tests/integration/setup-scripts/createExplicitGroups.php b/apps/user_ldap/tests/Integration/setup-scripts/createExplicitGroups.php similarity index 100% rename from apps/user_ldap/tests/integration/setup-scripts/createExplicitGroups.php rename to apps/user_ldap/tests/Integration/setup-scripts/createExplicitGroups.php diff --git a/apps/user_ldap/tests/integration/setup-scripts/createExplicitGroupsDifferentOU.php b/apps/user_ldap/tests/Integration/setup-scripts/createExplicitGroupsDifferentOU.php similarity index 100% rename from apps/user_ldap/tests/integration/setup-scripts/createExplicitGroupsDifferentOU.php rename to apps/user_ldap/tests/Integration/setup-scripts/createExplicitGroupsDifferentOU.php diff --git a/apps/user_ldap/tests/integration/setup-scripts/createExplicitUsers.php b/apps/user_ldap/tests/Integration/setup-scripts/createExplicitUsers.php similarity index 100% rename from apps/user_ldap/tests/integration/setup-scripts/createExplicitUsers.php rename to apps/user_ldap/tests/Integration/setup-scripts/createExplicitUsers.php diff --git a/apps/user_ldap/tests/integration/setup-scripts/createUsersWithoutDisplayName.php b/apps/user_ldap/tests/Integration/setup-scripts/createUsersWithoutDisplayName.php similarity index 100% rename from apps/user_ldap/tests/integration/setup-scripts/createUsersWithoutDisplayName.php rename to apps/user_ldap/tests/Integration/setup-scripts/createUsersWithoutDisplayName.php diff --git a/apps/user_ldap/tests/jobs/cleanup.php b/apps/user_ldap/tests/Jobs/CleanUpTest.php similarity index 97% rename from apps/user_ldap/tests/jobs/cleanup.php rename to apps/user_ldap/tests/Jobs/CleanUpTest.php index 18d4607117..24f646bd90 100644 --- a/apps/user_ldap/tests/jobs/cleanup.php +++ b/apps/user_ldap/tests/Jobs/CleanUpTest.php @@ -20,9 +20,9 @@ * */ -namespace OCA\user_ldap\tests; +namespace OCA\User_LDAP\Tests\Jobs; -class Test_CleanUp extends \PHPUnit_Framework_TestCase { +class CleanUpTest extends \Test\TestCase { public function getMocks() { $mocks = array(); $mocks['userBackend'] = diff --git a/apps/user_ldap/tests/mapping/abstractmappingtest.php b/apps/user_ldap/tests/Mapping/AbstractMappingTest.php similarity index 99% rename from apps/user_ldap/tests/mapping/abstractmappingtest.php rename to apps/user_ldap/tests/Mapping/AbstractMappingTest.php index a931a07a44..b800862d2c 100644 --- a/apps/user_ldap/tests/mapping/abstractmappingtest.php +++ b/apps/user_ldap/tests/Mapping/AbstractMappingTest.php @@ -20,7 +20,7 @@ * */ -namespace OCA\user_ldap\tests\mapping; +namespace OCA\User_LDAP\Tests\Mapping; abstract class AbstractMappingTest extends \Test\TestCase { abstract public function getMapper(\OCP\IDBConnection $dbMock); diff --git a/apps/user_ldap/tests/mapping/groupmapping.php b/apps/user_ldap/tests/Mapping/GroupMappingTest.php similarity index 86% rename from apps/user_ldap/tests/mapping/groupmapping.php rename to apps/user_ldap/tests/Mapping/GroupMappingTest.php index e25fae9329..5cdb9d463b 100644 --- a/apps/user_ldap/tests/mapping/groupmapping.php +++ b/apps/user_ldap/tests/Mapping/GroupMappingTest.php @@ -21,18 +21,18 @@ * */ -namespace OCA\user_ldap\tests\mapping; +namespace OCA\User_LDAP\Tests\Mapping; use OCA\User_LDAP\Mapping\GroupMapping; /** - * Class Test_GroupMapping + * Class GroupMappingTest * * @group DB * - * @package OCA\user_ldap\tests\mapping + * @package OCA\User_LDAP\Tests\Mapping */ -class Test_GroupMapping extends AbstractMappingTest { +class GroupMappingTest extends AbstractMappingTest { public function getMapper(\OCP\IDBConnection $dbMock) { return new GroupMapping($dbMock); } diff --git a/apps/user_ldap/tests/mapping/usermapping.php b/apps/user_ldap/tests/Mapping/UserMappingTest.php similarity index 86% rename from apps/user_ldap/tests/mapping/usermapping.php rename to apps/user_ldap/tests/Mapping/UserMappingTest.php index 6138740b81..9061896239 100644 --- a/apps/user_ldap/tests/mapping/usermapping.php +++ b/apps/user_ldap/tests/Mapping/UserMappingTest.php @@ -21,18 +21,18 @@ * */ -namespace OCA\user_ldap\tests\mapping; +namespace OCA\User_LDAP\Tests\Mapping; use OCA\User_LDAP\Mapping\UserMapping; /** - * Class Test_UserMapping + * Class UserMappingTest * * @group DB * - * @package OCA\user_ldap\tests\mapping + * @package OCA\User_LDAP\Tests\Mapping */ -class Test_UserMapping extends AbstractMappingTest { +class UserMappingTest extends AbstractMappingTest { public function getMapper(\OCP\IDBConnection $dbMock) { return new UserMapping($dbMock); } diff --git a/apps/user_ldap/tests/User/ManagerTest.php b/apps/user_ldap/tests/User/ManagerTest.php index 09eff64b9b..848918729d 100644 --- a/apps/user_ldap/tests/User/ManagerTest.php +++ b/apps/user_ldap/tests/User/ManagerTest.php @@ -32,7 +32,7 @@ use OCA\User_LDAP\User\Manager; * * @group DB * - * @package OCA\user_ldap\tests + * @package OCA\User_LDAP\Tests\User */ class ManagerTest extends \Test\TestCase { diff --git a/apps/user_ldap/tests/User/UserTest.php b/apps/user_ldap/tests/User/UserTest.php index 12ebc7227a..7362348c32 100644 --- a/apps/user_ldap/tests/User/UserTest.php +++ b/apps/user_ldap/tests/User/UserTest.php @@ -28,11 +28,11 @@ use OCA\User_LDAP\User\User; use OCP\IUserManager; /** - * Class Test_User_User + * Class UserTest * * @group DB * - * @package OCA\user_ldap\tests + * @package OCA\User_LDAP\Tests\User */ class UserTest extends \Test\TestCase { diff --git a/apps/user_ldap/tests/WizardTest.php b/apps/user_ldap/tests/WizardTest.php index d6ee5a473b..7a4a478d43 100644 --- a/apps/user_ldap/tests/WizardTest.php +++ b/apps/user_ldap/tests/WizardTest.php @@ -23,21 +23,16 @@ * */ -namespace OCA\User_LDAP\tests; +namespace OCA\User_LDAP\Tests; use \OCA\User_LDAP\Wizard; -// use \OCA\User_LDAP\User_LDAP as UserLDAP; -// use \OCA\User_LDAP\Access; -// use \OCA\User_LDAP\Configuration; -// use \OCA\User_LDAP\ILDAPWrapper; - /** * Class Test_Wizard * * @group DB * - * @package OCA\User_LDAP\tests + * @package OCA\User_LDAP\Tests */ class WizardTest extends \Test\TestCase { protected function setUp() {