diff --git a/lib/autoloader.php b/lib/autoloader.php
index 215da536e5b57543f86fe9bbdfec56b188957254..737836034389d29b49e3df5d0dcbb13f4e41e550 100644
--- a/lib/autoloader.php
+++ b/lib/autoloader.php
@@ -117,8 +117,6 @@ class Autoloader {
 			// This File is considered public API, so we make sure that the class
 			// can still be loaded, although the PSR-4 paths have not been loaded.
 			$paths[] = \OC::$SERVERROOT . '/tests/lib/TestCase.php';
-		} elseif (strpos($class, 'Test\\') === 0) {
-			$paths[] = \OC::$SERVERROOT . '/tests/lib/' . strtolower(str_replace('\\', '/', substr($class, 5)) . '.php');
 		}
 		return $paths;
 	}
diff --git a/tests/bootstrap.php b/tests/bootstrap.php
index e2b980b1c8030b123d9cea219d04a294ff0350ce..c58d9f585222b44c97a0eaffbef7cbceb8a3ec6d 100644
--- a/tests/bootstrap.php
+++ b/tests/bootstrap.php
@@ -10,7 +10,6 @@ require_once __DIR__ . '/../lib/base.php';
 
 \OC::$composerAutoloader->addPsr4('Test\\', OC::$SERVERROOT . '/tests/lib/', true);
 \OC::$composerAutoloader->addPsr4('Tests\\', OC::$SERVERROOT . '/tests/', true);
-\OC::$loader->addValidRoot(OC::$SERVERROOT . '/tests');
 
 // load all enabled apps
 \OC_App::loadApps();
diff --git a/tests/lib/activity/managertest.php b/tests/lib/Activity/ManagerTest.php
similarity index 100%
rename from tests/lib/activity/managertest.php
rename to tests/lib/Activity/ManagerTest.php
diff --git a/tests/lib/app/codechecker/codecheckertest.php b/tests/lib/App/CodeChecker/CodeCheckerTest.php
similarity index 100%
rename from tests/lib/app/codechecker/codecheckertest.php
rename to tests/lib/App/CodeChecker/CodeCheckerTest.php
diff --git a/tests/lib/app/codechecker/deprecationchecktest.php b/tests/lib/App/CodeChecker/DeprecationCheckTest.php
similarity index 100%
rename from tests/lib/app/codechecker/deprecationchecktest.php
rename to tests/lib/App/CodeChecker/DeprecationCheckTest.php
diff --git a/tests/lib/app/codechecker/infocheckertest.php b/tests/lib/App/CodeChecker/InfoCheckerTest.php
similarity index 95%
rename from tests/lib/app/codechecker/infocheckertest.php
rename to tests/lib/App/CodeChecker/InfoCheckerTest.php
index c6df5a715a1d1d5b10b1d7498cfbedfd35583b88..1032e800be1969ad3fbb54ab34fb19fa3ef4de38 100644
--- a/tests/lib/app/codechecker/infocheckertest.php
+++ b/tests/lib/App/CodeChecker/InfoCheckerTest.php
@@ -19,13 +19,14 @@
  *
  */
 
-namespace OC\App\CodeChecker;
+namespace Test\App\CodeChecker;
 
+use OC\App\CodeChecker\InfoChecker;
 use OC\App\InfoParser;
 use Test\TestCase;
 
 class InfoCheckerTest extends TestCase {
-	/** @var  InfoChecker */
+	/** @var InfoChecker */
 	protected $infoChecker;
 
 	public static function setUpBeforeClass() {
diff --git a/tests/lib/app/codechecker/mock/testlist.php b/tests/lib/App/CodeChecker/Mock/TestList.php
similarity index 100%
rename from tests/lib/app/codechecker/mock/testlist.php
rename to tests/lib/App/CodeChecker/Mock/TestList.php
diff --git a/tests/lib/app/codechecker/nodevisitortest.php b/tests/lib/App/CodeChecker/NodeVisitorTest.php
similarity index 98%
rename from tests/lib/app/codechecker/nodevisitortest.php
rename to tests/lib/App/CodeChecker/NodeVisitorTest.php
index 0b5aea283240b876e7726484a3504a64918422ac..ca0b6e9ccc1bc057562190ec08ea7f362cf6b2c3 100644
--- a/tests/lib/app/codechecker/nodevisitortest.php
+++ b/tests/lib/App/CodeChecker/NodeVisitorTest.php
@@ -6,7 +6,7 @@
  * See the COPYING-README file.
  */
 
-namespace Test\AppCodeChecker;
+namespace Test\App\CodeChecker;
 
 use OC\App\CodeChecker\CodeChecker;
 use OC\App\CodeChecker\EmptyCheck;
diff --git a/tests/lib/app/codechecker/strongcomparisonchecktest.php b/tests/lib/App/CodeChecker/StrongComparisonCheckTest.php
similarity index 100%
rename from tests/lib/app/codechecker/strongcomparisonchecktest.php
rename to tests/lib/App/CodeChecker/StrongComparisonCheckTest.php
diff --git a/tests/lib/app/dependencyanalyzer.php b/tests/lib/App/DependencyAnalyzerTest.php
similarity index 99%
rename from tests/lib/app/dependencyanalyzer.php
rename to tests/lib/App/DependencyAnalyzerTest.php
index eee0bc2908326edf7c9530da4a58605a41145ce9..7882f6dd031511c9738fa6d07e096e7074eecd10 100644
--- a/tests/lib/app/dependencyanalyzer.php
+++ b/tests/lib/App/DependencyAnalyzerTest.php
@@ -14,7 +14,7 @@ use OC\App\Platform;
 use OCP\IL10N;
 use Test\TestCase;
 
-class DependencyAnalyzer extends TestCase {
+class DependencyAnalyzerTest extends TestCase {
 
 	/** @var Platform */
 	private $platformMock;
diff --git a/tests/lib/app/infoparser.php b/tests/lib/App/InfoParserTest.php
similarity index 96%
rename from tests/lib/app/infoparser.php
rename to tests/lib/App/InfoParserTest.php
index cb89dd0131c0bdcda2c8438cd06c8be77c317d6d..7f52507bcf75d3daab03a2232694d9f63c3d20da 100644
--- a/tests/lib/app/infoparser.php
+++ b/tests/lib/App/InfoParserTest.php
@@ -13,7 +13,7 @@ use OC;
 use OCP\IURLGenerator;
 use Test\TestCase;
 
-class InfoParser extends TestCase {
+class InfoParserTest extends TestCase {
 
 	/** @var \OC\App\InfoParser */
 	private $parser;
diff --git a/tests/lib/app/manager.php b/tests/lib/App/ManagerTest.php
similarity index 99%
rename from tests/lib/app/manager.php
rename to tests/lib/App/ManagerTest.php
index ef7c01658e154cddbec984cc7565c81579ef540a..26584829b5f78a22c4cde890180369a9e5d93a35 100644
--- a/tests/lib/app/manager.php
+++ b/tests/lib/App/ManagerTest.php
@@ -19,7 +19,7 @@ use Test\TestCase;
  * @package Test\App
  * @group DB
  */
-class Manager extends TestCase {
+class ManagerTest extends TestCase {
 	/**
 	 * @return \OCP\IAppConfig | \PHPUnit_Framework_MockObject_MockObject
 	 */
diff --git a/tests/lib/app/platformrepository.php b/tests/lib/App/PlatformRepositoryTest.php
similarity index 98%
rename from tests/lib/app/platformrepository.php
rename to tests/lib/App/PlatformRepositoryTest.php
index 3d8849ce8ab6c2b6bb4cbb565e8dbe3859bc503e..783f8f473ffbeb0bd6b5561b33db44c338ac71ec 100644
--- a/tests/lib/app/platformrepository.php
+++ b/tests/lib/App/PlatformRepositoryTest.php
@@ -11,7 +11,7 @@ namespace Test\App;
 
 use OC;
 
-class PlatformRepository extends \Test\TestCase {
+class PlatformRepositoryTest extends \Test\TestCase {
 
 	/**
 	 * @dataProvider providesVersions
diff --git a/tests/lib/appconfig.php b/tests/lib/AppConfigTest.php
similarity index 99%
rename from tests/lib/appconfig.php
rename to tests/lib/AppConfigTest.php
index 12d9728c8682dee4c8fdc013f0aa9e8b74f116fd..520dbf66d360d749e60244c40e38226b9464d301 100644
--- a/tests/lib/appconfig.php
+++ b/tests/lib/AppConfigTest.php
@@ -10,13 +10,13 @@
 namespace Test;
 
 /**
- * Class AppConfig
+ * Class AppConfigTest
  *
  * @group DB
  *
  * @package Test
  */
-class AppConfig extends TestCase {
+class AppConfigTest extends TestCase {
 	/** @var \OCP\IAppConfig */
 	protected $appConfig;
 
diff --git a/tests/lib/appframework/AppTest.php b/tests/lib/AppFramework/AppTest.php
similarity index 100%
rename from tests/lib/appframework/AppTest.php
rename to tests/lib/AppFramework/AppTest.php
diff --git a/tests/lib/appframework/controller/ApiControllerTest.php b/tests/lib/AppFramework/Controller/ApiControllerTest.php
similarity index 100%
rename from tests/lib/appframework/controller/ApiControllerTest.php
rename to tests/lib/AppFramework/Controller/ApiControllerTest.php
diff --git a/tests/lib/appframework/controller/ControllerTest.php b/tests/lib/AppFramework/Controller/ControllerTest.php
similarity index 100%
rename from tests/lib/appframework/controller/ControllerTest.php
rename to tests/lib/AppFramework/Controller/ControllerTest.php
diff --git a/tests/lib/appframework/controller/OCSControllerTest.php b/tests/lib/AppFramework/Controller/OCSControllerTest.php
similarity index 100%
rename from tests/lib/appframework/controller/OCSControllerTest.php
rename to tests/lib/AppFramework/Controller/OCSControllerTest.php
diff --git a/tests/lib/appframework/db/EntityTest.php b/tests/lib/AppFramework/Db/EntityTest.php
similarity index 100%
rename from tests/lib/appframework/db/EntityTest.php
rename to tests/lib/AppFramework/Db/EntityTest.php
diff --git a/tests/lib/appframework/db/mappertest.php b/tests/lib/AppFramework/Db/MapperTest.php
similarity index 100%
rename from tests/lib/appframework/db/mappertest.php
rename to tests/lib/AppFramework/Db/MapperTest.php
diff --git a/tests/lib/appframework/db/mappertestutility.php b/tests/lib/AppFramework/Db/MapperTestUtility.php
similarity index 100%
rename from tests/lib/appframework/db/mappertestutility.php
rename to tests/lib/AppFramework/Db/MapperTestUtility.php
diff --git a/tests/lib/appframework/dependencyinjection/DIContainerTest.php b/tests/lib/AppFramework/DependencyInjection/DIContainerTest.php
similarity index 100%
rename from tests/lib/appframework/dependencyinjection/DIContainerTest.php
rename to tests/lib/AppFramework/DependencyInjection/DIContainerTest.php
diff --git a/tests/lib/appframework/http/ContentSecurityPolicyTest.php b/tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php
similarity index 100%
rename from tests/lib/appframework/http/ContentSecurityPolicyTest.php
rename to tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php
diff --git a/tests/lib/appframework/http/DataResponseTest.php b/tests/lib/AppFramework/Http/DataResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/DataResponseTest.php
rename to tests/lib/AppFramework/Http/DataResponseTest.php
diff --git a/tests/lib/appframework/http/DispatcherTest.php b/tests/lib/AppFramework/Http/DispatcherTest.php
similarity index 100%
rename from tests/lib/appframework/http/DispatcherTest.php
rename to tests/lib/AppFramework/Http/DispatcherTest.php
diff --git a/tests/lib/appframework/http/DownloadResponseTest.php b/tests/lib/AppFramework/Http/DownloadResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/DownloadResponseTest.php
rename to tests/lib/AppFramework/Http/DownloadResponseTest.php
diff --git a/tests/lib/appframework/http/EmptyContentSecurityPolicyTest.php b/tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php
similarity index 100%
rename from tests/lib/appframework/http/EmptyContentSecurityPolicyTest.php
rename to tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php
diff --git a/tests/lib/appframework/http/HttpTest.php b/tests/lib/AppFramework/Http/HttpTest.php
similarity index 100%
rename from tests/lib/appframework/http/HttpTest.php
rename to tests/lib/AppFramework/Http/HttpTest.php
diff --git a/tests/lib/appframework/http/JSONResponseTest.php b/tests/lib/AppFramework/Http/JSONResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/JSONResponseTest.php
rename to tests/lib/AppFramework/Http/JSONResponseTest.php
diff --git a/tests/lib/appframework/http/OCSResponseTest.php b/tests/lib/AppFramework/Http/OCSResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/OCSResponseTest.php
rename to tests/lib/AppFramework/Http/OCSResponseTest.php
diff --git a/tests/lib/appframework/http/RedirectResponseTest.php b/tests/lib/AppFramework/Http/RedirectResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/RedirectResponseTest.php
rename to tests/lib/AppFramework/Http/RedirectResponseTest.php
diff --git a/tests/lib/appframework/http/requeststream.php b/tests/lib/AppFramework/Http/RequestStream.php
similarity index 98%
rename from tests/lib/appframework/http/requeststream.php
rename to tests/lib/AppFramework/Http/RequestStream.php
index e1bf5c2c6bb08b8c3560cb94a7878f3de5dd0c62..8f6dffd4e91882bc3292a2a7478f2d638aa39071 100644
--- a/tests/lib/appframework/http/requeststream.php
+++ b/tests/lib/AppFramework/Http/RequestStream.php
@@ -1,4 +1,7 @@
 <?php
+
+namespace Test\AppFramework\Http;
+
 /**
  * Copy of http://dk1.php.net/manual/en/stream.streamwrapper.example-1.php
  * Used to simulate php://input for Request tests
diff --git a/tests/lib/appframework/http/RequestTest.php b/tests/lib/AppFramework/Http/RequestTest.php
similarity index 99%
rename from tests/lib/appframework/http/RequestTest.php
rename to tests/lib/AppFramework/Http/RequestTest.php
index 5b960908991edb46a5ec01b18cdfa2435abd6c9e..ddc2403d86685fc2d8bdd1c1bda10da5cd88129f 100644
--- a/tests/lib/appframework/http/RequestTest.php
+++ b/tests/lib/AppFramework/Http/RequestTest.php
@@ -34,11 +34,10 @@ class RequestTest extends \Test\TestCase {
 	protected function setUp() {
 		parent::setUp();
 
-		require_once __DIR__ . '/requeststream.php';
 		if (in_array('fakeinput', stream_get_wrappers())) {
 			stream_wrapper_unregister('fakeinput');
 		}
-		stream_wrapper_register('fakeinput', 'RequestStream');
+		stream_wrapper_register('fakeinput', 'Test\AppFramework\Http\RequestStream');
 
 		$this->secureRandom = $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock();
 		$this->config = $this->getMockBuilder('\OCP\IConfig')->getMock();
diff --git a/tests/lib/appframework/http/ResponseTest.php b/tests/lib/AppFramework/Http/ResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/ResponseTest.php
rename to tests/lib/AppFramework/Http/ResponseTest.php
diff --git a/tests/lib/appframework/http/StreamResponseTest.php b/tests/lib/AppFramework/Http/StreamResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/StreamResponseTest.php
rename to tests/lib/AppFramework/Http/StreamResponseTest.php
diff --git a/tests/lib/appframework/http/TemplateResponseTest.php b/tests/lib/AppFramework/Http/TemplateResponseTest.php
similarity index 100%
rename from tests/lib/appframework/http/TemplateResponseTest.php
rename to tests/lib/AppFramework/Http/TemplateResponseTest.php
diff --git a/tests/lib/appframework/middleware/MiddlewareDispatcherTest.php b/tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php
similarity index 100%
rename from tests/lib/appframework/middleware/MiddlewareDispatcherTest.php
rename to tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php
diff --git a/tests/lib/appframework/middleware/MiddlewareTest.php b/tests/lib/AppFramework/Middleware/MiddlewareTest.php
similarity index 100%
rename from tests/lib/appframework/middleware/MiddlewareTest.php
rename to tests/lib/AppFramework/Middleware/MiddlewareTest.php
diff --git a/tests/lib/appframework/middleware/security/CORSMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/CORSMiddlewareTest.php
similarity index 100%
rename from tests/lib/appframework/middleware/security/CORSMiddlewareTest.php
rename to tests/lib/AppFramework/Middleware/Security/CORSMiddlewareTest.php
diff --git a/tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
similarity index 100%
rename from tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php
rename to tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
diff --git a/tests/lib/appframework/middleware/sessionmiddlewaretest.php b/tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php
similarity index 100%
rename from tests/lib/appframework/middleware/sessionmiddlewaretest.php
rename to tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php
diff --git a/tests/lib/appframework/routing/RoutingTest.php b/tests/lib/AppFramework/Routing/RoutingTest.php
similarity index 100%
rename from tests/lib/appframework/routing/RoutingTest.php
rename to tests/lib/AppFramework/Routing/RoutingTest.php
diff --git a/tests/lib/appframework/utility/ControllerMethodReflectorTest.php b/tests/lib/AppFramework/Utility/ControllerMethodReflectorTest.php
similarity index 100%
rename from tests/lib/appframework/utility/ControllerMethodReflectorTest.php
rename to tests/lib/AppFramework/Utility/ControllerMethodReflectorTest.php
diff --git a/tests/lib/appframework/utility/SimpleContainerTest.php b/tests/lib/AppFramework/Utility/SimpleContainerTest.php
similarity index 100%
rename from tests/lib/appframework/utility/SimpleContainerTest.php
rename to tests/lib/AppFramework/Utility/SimpleContainerTest.php
diff --git a/tests/lib/archive/tartest.php b/tests/lib/Archive/TARTest.php
similarity index 100%
rename from tests/lib/archive/tartest.php
rename to tests/lib/Archive/TARTest.php
diff --git a/tests/lib/archive/testbase.php b/tests/lib/Archive/TestBase.php
similarity index 100%
rename from tests/lib/archive/testbase.php
rename to tests/lib/Archive/TestBase.php
diff --git a/tests/lib/archive/ziptest.php b/tests/lib/Archive/ZIPTest.php
similarity index 100%
rename from tests/lib/archive/ziptest.php
rename to tests/lib/Archive/ZIPTest.php
diff --git a/tests/lib/authentication/token/defaulttokencleanupjobtest.php b/tests/lib/Authentication/Token/DefaultTokenCleanupJobTest.php
similarity index 100%
rename from tests/lib/authentication/token/defaulttokencleanupjobtest.php
rename to tests/lib/Authentication/Token/DefaultTokenCleanupJobTest.php
diff --git a/tests/lib/authentication/token/defaulttokenmappertest.php b/tests/lib/Authentication/Token/DefaultTokenMapperTest.php
similarity index 100%
rename from tests/lib/authentication/token/defaulttokenmappertest.php
rename to tests/lib/Authentication/Token/DefaultTokenMapperTest.php
diff --git a/tests/lib/authentication/token/defaulttokenprovidertest.php b/tests/lib/Authentication/Token/DefaultTokenProviderTest.php
similarity index 100%
rename from tests/lib/authentication/token/defaulttokenprovidertest.php
rename to tests/lib/Authentication/Token/DefaultTokenProviderTest.php
diff --git a/tests/lib/autoloader.php b/tests/lib/AutoLoaderTest.php
similarity index 90%
rename from tests/lib/autoloader.php
rename to tests/lib/AutoLoaderTest.php
index 3669f514bee7982416a5471025779840b9b8dd39..a97ba3f768eefc0be35d368ff88acf3a38a651f7 100644
--- a/tests/lib/autoloader.php
+++ b/tests/lib/AutoLoaderTest.php
@@ -8,7 +8,7 @@
 
 namespace Test;
 
-class AutoLoader extends TestCase {
+class AutoLoaderTest extends TestCase {
 	/**
 	 * @var \OC\Autoloader $loader
 	 */
@@ -43,12 +43,6 @@ class AutoLoader extends TestCase {
 		], $this->loader->findClass('Test\TestCase'));
 	}
 
-	public function testLoadTestNamespace() {
-		$this->assertEquals([
-			\OC::$SERVERROOT . '/tests/lib/foo/bar.php'
-		], $this->loader->findClass('Test\Foo\Bar'));
-	}
-
 	public function testLoadCore() {
 		$this->assertEquals([
 			\OC::$SERVERROOT . '/lib/private/legacy/foo/bar.php', 
diff --git a/tests/lib/avatarmanagertest.php b/tests/lib/AvatarManagerTest.php
similarity index 100%
rename from tests/lib/avatarmanagertest.php
rename to tests/lib/AvatarManagerTest.php
diff --git a/tests/lib/avatartest.php b/tests/lib/AvatarTest.php
similarity index 100%
rename from tests/lib/avatartest.php
rename to tests/lib/AvatarTest.php
diff --git a/tests/lib/backgroundjob/dummyjoblist.php b/tests/lib/BackgroundJob/DummyJobList.php
similarity index 100%
rename from tests/lib/backgroundjob/dummyjoblist.php
rename to tests/lib/BackgroundJob/DummyJobList.php
diff --git a/tests/lib/backgroundjob/joblist.php b/tests/lib/BackgroundJob/JobListTest.php
similarity index 99%
rename from tests/lib/backgroundjob/joblist.php
rename to tests/lib/BackgroundJob/JobListTest.php
index fcc3c44081858be2375ce0b6a3b77c695b396c7a..6eed804bc3cbe614408ac47fbd58c7335dcaff9f 100644
--- a/tests/lib/backgroundjob/joblist.php
+++ b/tests/lib/BackgroundJob/JobListTest.php
@@ -18,7 +18,7 @@ use Test\TestCase;
  * @group DB
  * @package Test\BackgroundJob
  */
-class JobList extends TestCase {
+class JobListTest extends TestCase {
 	/** @var \OC\BackgroundJob\JobList */
 	protected $instance;
 
diff --git a/tests/lib/backgroundjob/job.php b/tests/lib/BackgroundJob/JobTest.php
similarity index 95%
rename from tests/lib/backgroundjob/job.php
rename to tests/lib/BackgroundJob/JobTest.php
index 12413e2c52aa9d1499b388867909dad3538f1e39..7923eef11ef6970014eceeb0692bc30e58ad6834 100644
--- a/tests/lib/backgroundjob/job.php
+++ b/tests/lib/BackgroundJob/JobTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\BackgroundJob;
 
-class Job extends \Test\TestCase {
+class JobTest extends \Test\TestCase {
 	private $run = false;
 
 	protected function setUp() {
diff --git a/tests/lib/backgroundjob/queuedjob.php b/tests/lib/BackgroundJob/QueuedJobTest.php
similarity index 92%
rename from tests/lib/backgroundjob/queuedjob.php
rename to tests/lib/BackgroundJob/QueuedJobTest.php
index 8d3cd6f907b7668b083b90f206cb995406ad8260..a3e9cc296a0db1d5829dd25f2fe314c75adc7307 100644
--- a/tests/lib/backgroundjob/queuedjob.php
+++ b/tests/lib/BackgroundJob/QueuedJobTest.php
@@ -12,7 +12,7 @@ class TestQueuedJob extends \OC\BackgroundJob\QueuedJob {
 	private $testCase;
 
 	/**
-	 * @param QueuedJob $testCase
+	 * @param QueuedJobTest $testCase
 	 */
 	public function __construct($testCase) {
 		$this->testCase = $testCase;
@@ -23,7 +23,7 @@ class TestQueuedJob extends \OC\BackgroundJob\QueuedJob {
 	}
 }
 
-class QueuedJob extends \Test\TestCase {
+class QueuedJobTest extends \Test\TestCase {
 	/**
 	 * @var DummyJobList $jobList
 	 */
diff --git a/tests/lib/backgroundjob/testjob.php b/tests/lib/BackgroundJob/TestJob.php
similarity index 95%
rename from tests/lib/backgroundjob/testjob.php
rename to tests/lib/BackgroundJob/TestJob.php
index 23fc4268d1aa3bd6db6331f1f5957d69fcf00881..a5ab445455060815d3a76b794634670ba8bb4de0 100644
--- a/tests/lib/backgroundjob/testjob.php
+++ b/tests/lib/BackgroundJob/TestJob.php
@@ -18,7 +18,7 @@ class TestJob extends \OC\BackgroundJob\Job {
 	private $callback;
 
 	/**
-	 * @param Job $testCase
+	 * @param JobTest $testCase
 	 * @param callable $callback
 	 */
 	public function __construct($testCase = null, $callback = null) {
diff --git a/tests/lib/backgroundjob/timedjob.php b/tests/lib/BackgroundJob/TimedJobTest.php
similarity index 95%
rename from tests/lib/backgroundjob/timedjob.php
rename to tests/lib/BackgroundJob/TimedJobTest.php
index 7d9bfe979af85d0f1b7a2c385061aa464dd6fe5a..5652a5c9901f88a593fd038db14c497c272fe41b 100644
--- a/tests/lib/backgroundjob/timedjob.php
+++ b/tests/lib/BackgroundJob/TimedJobTest.php
@@ -12,7 +12,7 @@ class TestTimedJob extends \OC\BackgroundJob\TimedJob {
 	private $testCase;
 
 	/**
-	 * @param TimedJob $testCase
+	 * @param TimedJobTest $testCase
 	 */
 	public function __construct($testCase) {
 		$this->setInterval(10);
@@ -24,7 +24,7 @@ class TestTimedJob extends \OC\BackgroundJob\TimedJob {
 	}
 }
 
-class TimedJob extends \Test\TestCase {
+class TimedJobTest extends \Test\TestCase {
 	/**
 	 * @var DummyJobList $jobList
 	 */
diff --git a/tests/lib/cache/cappedmemorycache.php b/tests/lib/Cache/CappedMemoryCacheTest.php
similarity index 96%
rename from tests/lib/cache/cappedmemorycache.php
rename to tests/lib/Cache/CappedMemoryCacheTest.php
index c9c74de72db55a78879a03dc06d11831d9ac67bc..27e5df4e2653d1aad141dd107631820a4dddc71b 100644
--- a/tests/lib/cache/cappedmemorycache.php
+++ b/tests/lib/Cache/CappedMemoryCacheTest.php
@@ -23,13 +23,13 @@
 namespace Test\Cache;
 
 /**
- * Class FileCache
+ * Class CappedMemoryCacheTest
  *
  * @group DB
  *
  * @package Test\Cache
  */
-class CappedMemoryCache extends TestCache {
+class CappedMemoryCacheTest extends TestCache {
 	public function setUp() {
 		parent::setUp();
 		$this->instance = new \OC\Cache\CappedMemoryCache();
diff --git a/tests/lib/cache/filecache.php b/tests/lib/Cache/FileCacheTest.php
similarity index 98%
rename from tests/lib/cache/filecache.php
rename to tests/lib/Cache/FileCacheTest.php
index a85b12671f3c55c90bc38328821ccd61dd307c39..d2725bf90338b980c54254e090a0011b3d0b8a96 100644
--- a/tests/lib/cache/filecache.php
+++ b/tests/lib/Cache/FileCacheTest.php
@@ -23,13 +23,13 @@
 namespace Test\Cache;
 
 /**
- * Class FileCache
+ * Class FileCacheTest
  *
  * @group DB
  *
  * @package Test\Cache
  */
-class FileCache extends TestCache {
+class FileCacheTest extends TestCache {
 	/**
 	 * @var string
 	 * */
diff --git a/tests/lib/cache/testcache.php b/tests/lib/Cache/TestCache.php
similarity index 100%
rename from tests/lib/cache/testcache.php
rename to tests/lib/Cache/TestCache.php
diff --git a/tests/lib/command/asyncbus.php b/tests/lib/Command/AsyncBusTest.php
similarity index 90%
rename from tests/lib/command/asyncbus.php
rename to tests/lib/Command/AsyncBusTest.php
index 183eaa29c37176dba2e679fb361fb4982c072140..8c1713f12607cafac02e3650c6c2bc1a414cdd9c 100644
--- a/tests/lib/command/asyncbus.php
+++ b/tests/lib/Command/AsyncBusTest.php
@@ -17,7 +17,7 @@ use Test\TestCase;
 
 class SimpleCommand implements ICommand {
 	public function handle() {
-		AsyncBus::$lastCommand = 'SimpleCommand';
+		AsyncBusTest::$lastCommand = 'SimpleCommand';
 	}
 }
 
@@ -29,7 +29,7 @@ class StateFullCommand implements ICommand {
 	}
 
 	public function handle() {
-		AsyncBus::$lastCommand = $this->state;
+		AsyncBusTest::$lastCommand = $this->state;
 	}
 }
 
@@ -37,18 +37,18 @@ class FilesystemCommand implements ICommand {
 	use FileAccess;
 
 	public function handle() {
-		AsyncBus::$lastCommand = 'FileAccess';
+		AsyncBusTest::$lastCommand = 'FileAccess';
 	}
 }
 
 function basicFunction() {
-	AsyncBus::$lastCommand = 'function';
+	AsyncBusTest::$lastCommand = 'function';
 }
 
 // clean class to prevent phpunit putting closure in $this
 class ThisClosureTest {
 	private function privateMethod() {
-		AsyncBus::$lastCommand = 'closure-this';
+		AsyncBusTest::$lastCommand = 'closure-this';
 	}
 
 	public function test(IBus $bus) {
@@ -58,7 +58,7 @@ class ThisClosureTest {
 	}
 }
 
-class AsyncBus extends TestCase {
+class AsyncBusTest extends TestCase {
 	/**
 	 * Basic way to check output from a command
 	 *
@@ -101,7 +101,7 @@ class AsyncBus extends TestCase {
 	}
 
 	public function testStaticCallable() {
-		$this->bus->push(['\Test\Command\AsyncBus', 'DummyCommand']);
+		$this->bus->push(['\Test\Command\AsyncBusTest', 'DummyCommand']);
 		$this->runJobs();
 		$this->assertEquals('static', self::$lastCommand);
 	}
@@ -121,7 +121,7 @@ class AsyncBus extends TestCase {
 
 	public function testClosure() {
 		$this->bus->push(function () {
-			AsyncBus::$lastCommand = 'closure';
+			AsyncBusTest::$lastCommand = 'closure';
 		});
 		$this->runJobs();
 		$this->assertEquals('closure', self::$lastCommand);
diff --git a/tests/lib/command/backgroundjobs.php b/tests/lib/Command/BackgroundJobsTest.php
similarity index 98%
rename from tests/lib/command/backgroundjobs.php
rename to tests/lib/Command/BackgroundJobsTest.php
index 7e99248053092187885f8ba061c855956c62bb88..6292d5d0e97405560e1b5acdf7a961c4d9aecbf5 100644
--- a/tests/lib/command/backgroundjobs.php
+++ b/tests/lib/Command/BackgroundJobsTest.php
@@ -33,7 +33,7 @@ use OC\Core\Command\Background\Cron;
 use OC\Core\Command\Background\WebCron;
 use OC\Core\Command\Background\Ajax;
 
-class BackgroundJobs extends TestCase {
+class BackgroundJobsTest extends TestCase {
 
 	public function testCronCommand() {
 		$config = \OC::$server->getConfig();
diff --git a/tests/lib/command/integrity/SignAppTest.php b/tests/lib/Command/Integrity/SignAppTest.php
similarity index 100%
rename from tests/lib/command/integrity/SignAppTest.php
rename to tests/lib/Command/Integrity/SignAppTest.php
diff --git a/tests/lib/command/integrity/SignCoreTest.php b/tests/lib/Command/Integrity/SignCoreTest.php
similarity index 100%
rename from tests/lib/command/integrity/SignCoreTest.php
rename to tests/lib/Command/Integrity/SignCoreTest.php
diff --git a/tests/lib/comments/commenttest.php b/tests/lib/Comments/CommentTest.php
similarity index 100%
rename from tests/lib/comments/commenttest.php
rename to tests/lib/Comments/CommentTest.php
diff --git a/tests/lib/comments/fakefactory.php b/tests/lib/Comments/FakeFactory.php
similarity index 100%
rename from tests/lib/comments/fakefactory.php
rename to tests/lib/Comments/FakeFactory.php
diff --git a/tests/lib/comments/fakemanager.php b/tests/lib/Comments/FakeManager.php
similarity index 100%
rename from tests/lib/comments/fakemanager.php
rename to tests/lib/Comments/FakeManager.php
diff --git a/tests/lib/comments/managertest.php b/tests/lib/Comments/ManagerTest.php
similarity index 100%
rename from tests/lib/comments/managertest.php
rename to tests/lib/Comments/ManagerTest.php
diff --git a/tests/lib/db/connection.php b/tests/lib/DB/ConnectionTest.php
similarity index 99%
rename from tests/lib/db/connection.php
rename to tests/lib/DB/ConnectionTest.php
index 4022bee511e0aa9bf1f916d559d43ad90bf5e471..b9c55c23339f36d36dcec8ce89a0f2f787ab4ea3 100644
--- a/tests/lib/db/connection.php
+++ b/tests/lib/DB/ConnectionTest.php
@@ -20,7 +20,7 @@ use OCP\DB\QueryBuilder\IQueryBuilder;
  *
  * @package Test\DB
  */
-class Connection extends \Test\TestCase {
+class ConnectionTest extends \Test\TestCase {
 	/**
 	 * @var \OCP\IDBConnection
 	 */
diff --git a/tests/lib/db/DBSchemaTest.php b/tests/lib/DB/DBSchemaTest.php
similarity index 100%
rename from tests/lib/db/DBSchemaTest.php
rename to tests/lib/DB/DBSchemaTest.php
diff --git a/tests/lib/db/LegacyDBTest.php b/tests/lib/DB/LegacyDBTest.php
similarity index 100%
rename from tests/lib/db/LegacyDBTest.php
rename to tests/lib/DB/LegacyDBTest.php
diff --git a/tests/lib/db/mdb2schemamanager.php b/tests/lib/DB/MDB2SchemaManagerTest.php
similarity index 96%
rename from tests/lib/db/mdb2schemamanager.php
rename to tests/lib/DB/MDB2SchemaManagerTest.php
index fd412bdec2da27de836521fe4b9f983405f43d57..93078b4f7222394b91da72b867d18992ab350352 100644
--- a/tests/lib/db/mdb2schemamanager.php
+++ b/tests/lib/DB/MDB2SchemaManagerTest.php
@@ -18,7 +18,7 @@ use Doctrine\DBAL\Platforms\OraclePlatform;
  *
  * @package Test\DB
  */
-class MDB2SchemaManager extends \Test\TestCase {
+class MDB2SchemaManagerTest extends \Test\TestCase {
 
 	protected function tearDown() {
 		// do not drop the table for Oracle as it will create a bogus transaction
diff --git a/tests/lib/db/mdb2schemareader.php b/tests/lib/DB/MDB2SchemaReaderTest.php
similarity index 98%
rename from tests/lib/db/mdb2schemareader.php
rename to tests/lib/DB/MDB2SchemaReaderTest.php
index 7939c782e80dd6ffc52d468782aa6a4bdfa20b33..22c0ba28569bb22f58b8aa3e2f6bb5052f8db98a 100644
--- a/tests/lib/db/mdb2schemareader.php
+++ b/tests/lib/DB/MDB2SchemaReaderTest.php
@@ -11,7 +11,7 @@ namespace Test\DB;
 
 use Doctrine\DBAL\Platforms\MySqlPlatform;
 
-class MDB2SchemaReader extends \Test\TestCase {
+class MDB2SchemaReaderTest extends \Test\TestCase {
 	/**
 	 * @var \OC\DB\MDB2SchemaReader $reader
 	 */
diff --git a/tests/lib/db/migrator.php b/tests/lib/DB/MigratorTest.php
similarity index 98%
rename from tests/lib/db/migrator.php
rename to tests/lib/DB/MigratorTest.php
index 84a98c1e3387c7fed97fc9c1c9d9d58b88e60f0c..e4f45c4bb86053054f584be955f991c27cffc6f6 100644
--- a/tests/lib/db/migrator.php
+++ b/tests/lib/DB/MigratorTest.php
@@ -16,13 +16,13 @@ use \Doctrine\DBAL\Schema\SchemaConfig;
 use OCP\IConfig;
 
 /**
- * Class Migrator
+ * Class MigratorTest
  *
  * @group DB
  *
  * @package Test\DB
  */
-class Migrator extends \Test\TestCase {
+class MigratorTest extends \Test\TestCase {
 	/**
 	 * @var \Doctrine\DBAL\Connection $connection
 	 */
diff --git a/tests/lib/db/mysqlmigration.php b/tests/lib/DB/MySqlMigrationTest.php
similarity index 96%
rename from tests/lib/db/mysqlmigration.php
rename to tests/lib/DB/MySqlMigrationTest.php
index 42ed6ba7251fa9f7bed91d8a8d799d0684e00e33..cdc7ef47784f68bf455a30496892f9468bbd3f6d 100644
--- a/tests/lib/db/mysqlmigration.php
+++ b/tests/lib/DB/MySqlMigrationTest.php
@@ -13,7 +13,7 @@ namespace Test\DB;
  *
  * @group DB
  */
-class MySqlMigration extends \Test\TestCase {
+class MySqlMigrationTest extends \Test\TestCase {
 
 	/** @var \Doctrine\DBAL\Connection */
 	private $connection;
diff --git a/tests/lib/db/querybuilder/expressionbuildertest.php b/tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php
similarity index 100%
rename from tests/lib/db/querybuilder/expressionbuildertest.php
rename to tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php
diff --git a/tests/lib/db/querybuilder/querybuildertest.php b/tests/lib/DB/QueryBuilder/QueryBuilderTest.php
similarity index 100%
rename from tests/lib/db/querybuilder/querybuildertest.php
rename to tests/lib/DB/QueryBuilder/QueryBuilderTest.php
diff --git a/tests/lib/db/querybuilder/quotehelpertest.php b/tests/lib/DB/QueryBuilder/QuoteHelperTest.php
similarity index 100%
rename from tests/lib/db/querybuilder/quotehelpertest.php
rename to tests/lib/DB/QueryBuilder/QuoteHelperTest.php
diff --git a/tests/lib/db/sqlitemigration.php b/tests/lib/DB/SqliteMigrationTest.php
similarity index 95%
rename from tests/lib/db/sqlitemigration.php
rename to tests/lib/DB/SqliteMigrationTest.php
index 176b947e310d4e07448deec7bbeec69d6a7392f3..76002e1afce3c1a522366b3c4eaf9594bcc2b1dd 100644
--- a/tests/lib/db/sqlitemigration.php
+++ b/tests/lib/DB/SqliteMigrationTest.php
@@ -13,7 +13,7 @@ namespace Test\DB;
  *
  * @group DB
  */
-class SqliteMigration extends \Test\TestCase {
+class SqliteMigrationTest extends \Test\TestCase {
 
 	/** @var \Doctrine\DBAL\Connection */
 	private $connection;
diff --git a/tests/lib/db/testschema.xml b/tests/lib/DB/testschema.xml
similarity index 100%
rename from tests/lib/db/testschema.xml
rename to tests/lib/DB/testschema.xml
diff --git a/tests/lib/db/ts-autoincrement-after.xml b/tests/lib/DB/ts-autoincrement-after.xml
similarity index 100%
rename from tests/lib/db/ts-autoincrement-after.xml
rename to tests/lib/DB/ts-autoincrement-after.xml
diff --git a/tests/lib/db/ts-autoincrement-before.xml b/tests/lib/DB/ts-autoincrement-before.xml
similarity index 100%
rename from tests/lib/db/ts-autoincrement-before.xml
rename to tests/lib/DB/ts-autoincrement-before.xml
diff --git a/tests/lib/datetimeformatter.php b/tests/lib/DateTimeFormatterTest.php
similarity index 99%
rename from tests/lib/datetimeformatter.php
rename to tests/lib/DateTimeFormatterTest.php
index bf1ef3b84dc644a15356f7c55a3d35f88cd710c3..0d185128e2735475168c82e6dab910a33e50c710 100644
--- a/tests/lib/datetimeformatter.php
+++ b/tests/lib/DateTimeFormatterTest.php
@@ -8,7 +8,7 @@
 
 namespace Test;
 
-class DateTimeFormatter extends TestCase {
+class DateTimeFormatterTest extends TestCase {
 	/** @var \OC\DateTimeFormatter */
 	protected $formatter;
 	static protected $oneMinute = 60;
diff --git a/tests/lib/encryption/decryptalltest.php b/tests/lib/Encryption/DecryptAllTest.php
similarity index 100%
rename from tests/lib/encryption/decryptalltest.php
rename to tests/lib/Encryption/DecryptAllTest.php
diff --git a/tests/lib/encryption/encryptionwrappertest.php b/tests/lib/Encryption/EncryptionWrapperTest.php
similarity index 100%
rename from tests/lib/encryption/encryptionwrappertest.php
rename to tests/lib/Encryption/EncryptionWrapperTest.php
diff --git a/tests/lib/encryption/keys/storagetest.php b/tests/lib/Encryption/Keys/StorageTest.php
similarity index 100%
rename from tests/lib/encryption/keys/storagetest.php
rename to tests/lib/Encryption/Keys/StorageTest.php
diff --git a/tests/lib/encryption/managertest.php b/tests/lib/Encryption/ManagerTest.php
similarity index 100%
rename from tests/lib/encryption/managertest.php
rename to tests/lib/Encryption/ManagerTest.php
diff --git a/tests/lib/encryption/updatetest.php b/tests/lib/Encryption/UpdateTest.php
similarity index 100%
rename from tests/lib/encryption/updatetest.php
rename to tests/lib/Encryption/UpdateTest.php
diff --git a/tests/lib/encryption/utiltest.php b/tests/lib/Encryption/UtilTest.php
similarity index 100%
rename from tests/lib/encryption/utiltest.php
rename to tests/lib/Encryption/UtilTest.php
diff --git a/tests/lib/filechunking.php b/tests/lib/FileChunkingTest.php
similarity index 97%
rename from tests/lib/filechunking.php
rename to tests/lib/FileChunkingTest.php
index 2f3f411275d83e9114344ad732547c71ce3db25a..66888285d23bb16290191382c017f8574d2cfa6d 100644
--- a/tests/lib/filechunking.php
+++ b/tests/lib/FileChunkingTest.php
@@ -20,7 +20,7 @@
  */
 namespace Test;
 
-class FileChunking extends \Test\TestCase {
+class FileChunkingTest extends \Test\TestCase {
 
 	public function dataIsComplete() {
 		return [
diff --git a/tests/lib/files/cache/cache.php b/tests/lib/Files/Cache/CacheTest.php
similarity index 99%
rename from tests/lib/files/cache/cache.php
rename to tests/lib/Files/Cache/CacheTest.php
index 3201e2d03fede03849006a47329291b781ee454e..615bb32f62c6e0e1713ac7d51771fc5172f62b4a 100644
--- a/tests/lib/files/cache/cache.php
+++ b/tests/lib/Files/Cache/CacheTest.php
@@ -16,13 +16,13 @@ class LongId extends \OC\Files\Storage\Temporary {
 }
 
 /**
- * Class Cache
+ * Class CacheTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class Cache extends \Test\TestCase {
+class CacheTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Temporary $storage ;
 	 */
diff --git a/tests/lib/files/cache/homecache.php b/tests/lib/Files/Cache/HomeCacheTest.php
similarity index 98%
rename from tests/lib/files/cache/homecache.php
rename to tests/lib/Files/Cache/HomeCacheTest.php
index e133d0afc55909ea2b1649dd847d2e5062f6357a..a144b8cabb88d9cc5ca79a05c6fe0ec47158106f 100644
--- a/tests/lib/files/cache/homecache.php
+++ b/tests/lib/Files/Cache/HomeCacheTest.php
@@ -44,13 +44,13 @@ class DummyUser extends \OC\User\User {
 }
 
 /**
- * Class HomeCache
+ * Class HomeCacheTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class HomeCache extends \Test\TestCase {
+class HomeCacheTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Home $storage
 	 */
diff --git a/tests/lib/files/cache/movefromcachetraittest.php b/tests/lib/Files/Cache/MoveFromCacheTraitTest.php
similarity index 89%
rename from tests/lib/files/cache/movefromcachetraittest.php
rename to tests/lib/Files/Cache/MoveFromCacheTraitTest.php
index 614c259d996603fa8c43aba8c8c13afc9106eb86..3d4a55c0722db1ca527f955112557c126c897caa 100644
--- a/tests/lib/files/cache/movefromcachetraittest.php
+++ b/tests/lib/Files/Cache/MoveFromCacheTraitTest.php
@@ -15,11 +15,11 @@ class FallBackCrossCacheMoveCache extends \OC\Files\Cache\Cache {
 }
 
 /**
- * Class Cache
+ * Class MoveFromCacheTraitTest
  *
  * @group DB
  */
-class MoveFromCacheTraitTest extends Cache {
+class MoveFromCacheTraitTest extends CacheTest {
 	protected function setUp() {
 		parent::setUp();
 
diff --git a/tests/lib/files/cache/scanner.php b/tests/lib/Files/Cache/ScannerTest.php
similarity index 99%
rename from tests/lib/files/cache/scanner.php
rename to tests/lib/Files/Cache/ScannerTest.php
index b1eb3f589e898e99b2f69c4176559dec26ea4971..4a93f3ee01436fa6917e078723bb7685aba73e8c 100644
--- a/tests/lib/files/cache/scanner.php
+++ b/tests/lib/Files/Cache/ScannerTest.php
@@ -10,13 +10,13 @@ namespace Test\Files\Cache;
 use OC\Files\Cache\CacheEntry;
 
 /**
- * Class Scanner
+ * Class ScannerTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class Scanner extends \Test\TestCase {
+class ScannerTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Storage $storage
 	 */
diff --git a/tests/lib/files/cache/updaterlegacy.php b/tests/lib/Files/Cache/UpdaterLegacyTest.php
similarity index 99%
rename from tests/lib/files/cache/updaterlegacy.php
rename to tests/lib/Files/Cache/UpdaterLegacyTest.php
index 09688afd465fa728876674bd662ed3135dfbbae1..7d247968ca97a397a9a3e1c23e1f199aea6f9d8e 100644
--- a/tests/lib/files/cache/updaterlegacy.php
+++ b/tests/lib/Files/Cache/UpdaterLegacyTest.php
@@ -13,13 +13,13 @@ use OC\Files\Storage\Temporary;
 use OC\Files\View;
 
 /**
- * Class UpdaterLegacy
+ * Class UpdaterLegacyTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class UpdaterLegacy extends \Test\TestCase {
+class UpdaterLegacyTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Storage $storage
 	 */
diff --git a/tests/lib/files/cache/updater.php b/tests/lib/Files/Cache/UpdaterTest.php
similarity index 99%
rename from tests/lib/files/cache/updater.php
rename to tests/lib/Files/Cache/UpdaterTest.php
index cdffac464dc379db68211fd9cbace2588bfcd1f8..54fb3f3fc979a3697e136bd79903c22a0943208a 100644
--- a/tests/lib/files/cache/updater.php
+++ b/tests/lib/Files/Cache/UpdaterTest.php
@@ -13,13 +13,13 @@ use OC\Files\Storage\Temporary;
 use OC\Files\View;
 
 /**
- * Class Updater
+ * Class UpdaterTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class Updater extends \Test\TestCase {
+class UpdaterTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Storage
 	 */
diff --git a/tests/lib/files/cache/watcher.php b/tests/lib/Files/Cache/WatcherTest.php
similarity index 98%
rename from tests/lib/files/cache/watcher.php
rename to tests/lib/Files/Cache/WatcherTest.php
index cb90e92b4772abd60697c2d8fb638dac0c87d662..3834b5591ff1d1225b571dfccccb58627a8c8129 100644
--- a/tests/lib/files/cache/watcher.php
+++ b/tests/lib/Files/Cache/WatcherTest.php
@@ -9,13 +9,13 @@
 namespace Test\Files\Cache;
 
 /**
- * Class Watcher
+ * Class WatcherTest
  *
  * @group DB
  *
  * @package Test\Files\Cache
  */
-class Watcher extends \Test\TestCase {
+class WatcherTest extends \Test\TestCase {
 
 	/**
 	 * @var \OC\Files\Storage\Storage[] $storages
diff --git a/tests/lib/files/cache/wrapper/cachejail.php b/tests/lib/Files/Cache/Wrapper/CacheJailTest.php
similarity index 96%
rename from tests/lib/files/cache/wrapper/cachejail.php
rename to tests/lib/Files/Cache/Wrapper/CacheJailTest.php
index 9ddf3e9c61c4c7d6378ce64574ee6855be3bdbbb..6ef6716f72138d533f826660cc79f9ae33eba160 100644
--- a/tests/lib/files/cache/wrapper/cachejail.php
+++ b/tests/lib/Files/Cache/Wrapper/CacheJailTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Cache\Wrapper;
 
-use Test\Files\Cache\Cache;
+use Test\Files\Cache\CacheTest;
 
 /**
  * Class CacheJail
@@ -17,7 +17,7 @@ use Test\Files\Cache\Cache;
  *
  * @package Test\Files\Cache\Wrapper
  */
-class CacheJail extends Cache {
+class CacheJailTest extends CacheTest {
 	/**
 	 * @var \OC\Files\Cache\Cache $sourceCache
 	 */
diff --git a/tests/lib/files/cache/wrapper/cachepermissionsmask.php b/tests/lib/Files/Cache/Wrapper/CachePermissionsMaskTest.php
similarity index 97%
rename from tests/lib/files/cache/wrapper/cachepermissionsmask.php
rename to tests/lib/Files/Cache/Wrapper/CachePermissionsMaskTest.php
index a4cc7edba3718b4f48b138714288beae72ab454b..c12b35867ff0a8cbe4127c4e6c923ec67a0b72c3 100644
--- a/tests/lib/files/cache/wrapper/cachepermissionsmask.php
+++ b/tests/lib/Files/Cache/Wrapper/CachePermissionsMaskTest.php
@@ -9,7 +9,7 @@
 namespace Test\Files\Cache\Wrapper;
 
 use OCP\Constants;
-use Test\Files\Cache\Cache;
+use Test\Files\Cache\CacheTest;
 
 /**
  * Class CachePermissionsMask
@@ -18,7 +18,7 @@ use Test\Files\Cache\Cache;
  *
  * @package Test\Files\Cache\Wrapper
  */
-class CachePermissionsMask extends Cache {
+class CachePermissionsMaskTest extends CacheTest {
 	/**
 	 * @var \OC\Files\Cache\Cache $sourceCache
 	 */
diff --git a/tests/lib/files/config/usermountcache.php b/tests/lib/Files/Config/UserMountCacheTest.php
similarity index 99%
rename from tests/lib/files/config/usermountcache.php
rename to tests/lib/Files/Config/UserMountCacheTest.php
index 070c2f6176d33b4ea09b36135ac164860935288c..e7554fc36d9552760adb9e784f9fde029384e98c 100644
--- a/tests/lib/files/config/usermountcache.php
+++ b/tests/lib/Files/Config/UserMountCacheTest.php
@@ -21,7 +21,7 @@ use Test\Util\User\Dummy;
 /**
  * @group DB
  */
-class UserMountCache extends TestCase {
+class UserMountCacheTest extends TestCase {
 	/**
 	 * @var IDBConnection
 	 */
diff --git a/tests/lib/files/etagtest.php b/tests/lib/Files/EtagTest.php
similarity index 100%
rename from tests/lib/files/etagtest.php
rename to tests/lib/Files/EtagTest.php
diff --git a/tests/lib/files/filesystem.php b/tests/lib/Files/FilesystemTest.php
similarity index 99%
rename from tests/lib/files/filesystem.php
rename to tests/lib/Files/FilesystemTest.php
index b5a3e147259933ae766d95436127df02c22b24d0..a4a4345d2f93935c9ccac222e72ca913a829e3d8 100644
--- a/tests/lib/files/filesystem.php
+++ b/tests/lib/Files/FilesystemTest.php
@@ -52,13 +52,13 @@ class DummyMountProvider implements IMountProvider {
 }
 
 /**
- * Class Filesystem
+ * Class FilesystemTest
  *
  * @group DB
  *
  * @package Test\Files
  */
-class Filesystem extends \Test\TestCase {
+class FilesystemTest extends \Test\TestCase {
 
 	const TEST_FILESYSTEM_USER1 = "test-filesystem-user1";
 	const TEST_FILESYSTEM_USER2 = "test-filesystem-user1";
diff --git a/tests/lib/files/mount/manager.php b/tests/lib/Files/Mount/ManagerTest.php
similarity index 98%
rename from tests/lib/files/mount/manager.php
rename to tests/lib/Files/Mount/ManagerTest.php
index 78322b47d5017089044f04266c8970c33c1a7e46..46ae597f56b34aefcaa42960e9e49670c06c1140 100644
--- a/tests/lib/files/mount/manager.php
+++ b/tests/lib/Files/Mount/ManagerTest.php
@@ -16,7 +16,7 @@ class LongId extends Temporary {
 	}
 }
 
-class Manager extends \Test\TestCase {
+class ManagerTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Mount\Manager
 	 */
diff --git a/tests/lib/files/mount/mountpoint.php b/tests/lib/Files/Mount/MountPointTest.php
similarity index 93%
rename from tests/lib/files/mount/mountpoint.php
rename to tests/lib/Files/Mount/MountPointTest.php
index 29610e6058da8954ea3a7c462ec9aff5bac0f79d..392f10c71704c1e4f1b222ee5cd765531b81e61e 100644
--- a/tests/lib/files/mount/mountpoint.php
+++ b/tests/lib/Files/Mount/MountPointTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Mount;
 
-class MountPoint extends \Test\TestCase {
+class MountPointTest extends \Test\TestCase {
 
 	public function testGetStorage() {
 		$storage = $this->getMock('\OCP\Files\Storage');
@@ -23,7 +23,7 @@ class MountPoint extends \Test\TestCase {
 
 		$mountPoint = new \OC\Files\Mount\MountPoint(
 			// just use this because a real class is needed
-			'\Test\Files\Mount\MountPoint',
+			'\Test\Files\Mount\MountPointTest',
 			'/mountpoint',
 			null,
 			$loader
@@ -50,7 +50,7 @@ class MountPoint extends \Test\TestCase {
 
 		$mountPoint = new \OC\Files\Mount\MountPoint(
 			// just use this because a real class is needed
-			'\Test\Files\Mount\MountPoint',
+			'\Test\Files\Mount\MountPointTest',
 			'/mountpoint',
 			null,
 			$loader
diff --git a/tests/lib/files/mount/mount.php b/tests/lib/Files/Mount/MountTest.php
similarity index 97%
rename from tests/lib/files/mount/mount.php
rename to tests/lib/Files/Mount/MountTest.php
index 584766de8362984e9340609b691a5b80685931e1..f21095f2fa52b2cd65a03369bb0a76813bebf468 100644
--- a/tests/lib/files/mount/mount.php
+++ b/tests/lib/Files/Mount/MountTest.php
@@ -12,7 +12,7 @@ namespace Test\Files\Mount;
 use OC\Files\Storage\StorageFactory;
 use OC\Files\Storage\Wrapper\Wrapper;
 
-class Mount extends \Test\TestCase {
+class MountTest extends \Test\TestCase {
 	public function testFromStorageObject() {
 		$storage = $this->getMockBuilder('\OC\Files\Storage\Temporary')
 			->disableOriginalConstructor()
diff --git a/tests/lib/files/node/file.php b/tests/lib/Files/Node/FileTest.php
similarity index 99%
rename from tests/lib/files/node/file.php
rename to tests/lib/Files/Node/FileTest.php
index ccc777c499ffa8ffa789e62632c6380782891b49..180c7b12ce47e5a2095ffe1aa254c42ff32c9c26 100644
--- a/tests/lib/files/node/file.php
+++ b/tests/lib/Files/Node/FileTest.php
@@ -13,7 +13,7 @@ use OCP\Files\NotFoundException;
 use OCP\Files\NotPermittedException;
 use OC\Files\View;
 
-class File extends \Test\TestCase {
+class FileTest extends \Test\TestCase {
 	private $user;
 
 	protected function setUp() {
diff --git a/tests/lib/files/node/folder.php b/tests/lib/Files/Node/FolderTest.php
similarity index 99%
rename from tests/lib/files/node/folder.php
rename to tests/lib/Files/Node/FolderTest.php
index f6d488d65909044812d9f705216bb01a1e2487a4..7ce9fff1419486e7de4dd80b2433602721244895 100644
--- a/tests/lib/files/node/folder.php
+++ b/tests/lib/Files/Node/FolderTest.php
@@ -17,13 +17,13 @@ use OCP\Files\NotPermittedException;
 use OC\Files\View;
 
 /**
- * Class Folder
+ * Class FolderTest
  *
  * @group DB
  *
  * @package Test\Files\Node
  */
-class Folder extends \Test\TestCase {
+class FolderTest extends \Test\TestCase {
 	private $user;
 
 	protected function setUp() {
diff --git a/tests/lib/files/node/hookconnector.php b/tests/lib/Files/Node/HookConnectorTest.php
similarity index 98%
rename from tests/lib/files/node/hookconnector.php
rename to tests/lib/Files/Node/HookConnectorTest.php
index e2a5e1906879c007ae62b657768a633c30942ca2..7245dd375935ba45a5c7be435b61dfbec99f0f6d 100644
--- a/tests/lib/files/node/hookconnector.php
+++ b/tests/lib/Files/Node/HookConnectorTest.php
@@ -18,13 +18,13 @@ use Test\Traits\MountProviderTrait;
 use Test\Traits\UserTrait;
 
 /**
- * Class HookConnector
+ * Class HookConnectorTest
  *
  * @group DB
  *
  * @package Test\Files\Node
  */
-class HookConnector extends TestCase {
+class HookConnectorTest extends TestCase {
 	use UserTrait;
 	use MountProviderTrait;
 
diff --git a/tests/lib/files/node/IntegrationTest.php b/tests/lib/Files/Node/IntegrationTest.php
similarity index 99%
rename from tests/lib/files/node/IntegrationTest.php
rename to tests/lib/Files/Node/IntegrationTest.php
index e11f9bca4ea864d21e2e2f534275590f33959753..f52e0623e14e59c7910de27cfa349257e7b49dd1 100644
--- a/tests/lib/files/node/IntegrationTest.php
+++ b/tests/lib/Files/Node/IntegrationTest.php
@@ -14,7 +14,7 @@ use OC\Files\View;
 use OC\User\User;
 
 /**
- * Class IntegrationTests
+ * Class IntegrationTest
  *
  * @group DB
  *
diff --git a/tests/lib/files/node/node.php b/tests/lib/Files/Node/NodeTest.php
similarity index 99%
rename from tests/lib/files/node/node.php
rename to tests/lib/Files/Node/NodeTest.php
index a1693b034fac0f996a6c2435817b04c04fb8df65..a9575507b4f13a5590be793812251dc71e980fe5 100644
--- a/tests/lib/files/node/node.php
+++ b/tests/lib/Files/Node/NodeTest.php
@@ -10,7 +10,7 @@ namespace Test\Files\Node;
 
 use OC\Files\FileInfo;
 
-class Node extends \Test\TestCase {
+class NodeTest extends \Test\TestCase {
 	private $user;
 
 	protected function setUp() {
diff --git a/tests/lib/files/node/root.php b/tests/lib/Files/Node/RootTest.php
similarity index 98%
rename from tests/lib/files/node/root.php
rename to tests/lib/Files/Node/RootTest.php
index 9c77959869d6caabdfec6834828e8e3dac92809e..1b4824cba767b38c15ee7c38b167134307218265 100644
--- a/tests/lib/files/node/root.php
+++ b/tests/lib/Files/Node/RootTest.php
@@ -15,7 +15,7 @@ use OC\Files\Mount\Manager;
 /**
  * @group DB
  */
-class Root extends \Test\TestCase {
+class RootTest extends \Test\TestCase {
 	private $user;
 
 	protected function setUp() {
diff --git a/tests/lib/files/objectstore/noopscanner.php b/tests/lib/Files/ObjectStore/NoopScannerTest.php
similarity index 95%
rename from tests/lib/files/objectstore/noopscanner.php
rename to tests/lib/Files/ObjectStore/NoopScannerTest.php
index fba6619d42b68b1b924b7bc7da2b1cd86013766f..16bd325a8dfe1e067f4d9b8a6b345ec5d598fc54 100644
--- a/tests/lib/files/objectstore/noopscanner.php
+++ b/tests/lib/Files/ObjectStore/NoopScannerTest.php
@@ -9,9 +9,9 @@
  * later.
  * See the COPYING-README file.
  */
-namespace Test\Files\Cache\ObjectStore;
+namespace Test\Files\ObjectStore;
 
-class NoopScanner extends \Test\TestCase {
+class NoopScannerTest extends \Test\TestCase {
 	/** @var \OC\Files\Storage\Storage $storage */
 	private $storage;
 
diff --git a/tests/lib/files/objectstore/SwiftTest.php b/tests/lib/Files/ObjectStore/SwiftTest.php
similarity index 99%
rename from tests/lib/files/objectstore/SwiftTest.php
rename to tests/lib/Files/ObjectStore/SwiftTest.php
index 4731936627de29c99a5eb55a864828f4eedfe3d9..9f69e040f87e5cb5fc16fa7b9a9ddfd66384a037 100644
--- a/tests/lib/files/objectstore/SwiftTest.php
+++ b/tests/lib/Files/ObjectStore/SwiftTest.php
@@ -18,7 +18,7 @@
  *
  */
 
-namespace Test\Files\Cache\ObjectStore;
+namespace Test\Files\ObjectStore;
 
 use OC\Files\ObjectStore\ObjectStoreStorage;
 use OC\Files\ObjectStore\Swift;
diff --git a/tests/lib/files/pathverificationtest.php b/tests/lib/Files/PathVerificationTest.php
similarity index 99%
rename from tests/lib/files/pathverificationtest.php
rename to tests/lib/Files/PathVerificationTest.php
index ea9859c862ce5012d110ccaf053c525484d278bc..9ce9416455f06563b7179d01399751eb4215982e 100644
--- a/tests/lib/files/pathverificationtest.php
+++ b/tests/lib/Files/PathVerificationTest.php
@@ -11,7 +11,7 @@ use OC\Files\Storage\Local;
 use OC\Files\View;
 
 /**
- * Class PathVerification
+ * Class PathVerificationTest
  *
  * @group DB
  *
diff --git a/tests/lib/files/storage/commontest.php b/tests/lib/Files/Storage/CommonTest.php
similarity index 100%
rename from tests/lib/files/storage/commontest.php
rename to tests/lib/Files/Storage/CommonTest.php
diff --git a/tests/lib/files/storage/copydirectory.php b/tests/lib/Files/Storage/CopyDirectoryTest.php
similarity index 95%
rename from tests/lib/files/storage/copydirectory.php
rename to tests/lib/Files/Storage/CopyDirectoryTest.php
index bc066268cda69ad0309733b38af87adb742f44fd..74b8148aa369332791e7358fd3578232b256a034 100644
--- a/tests/lib/files/storage/copydirectory.php
+++ b/tests/lib/Files/Storage/CopyDirectoryTest.php
@@ -37,13 +37,13 @@ class CopyDirectoryStorage extends StorageNoRecursiveCopy {
 }
 
 /**
- * Class CopyDirectory
+ * Class CopyDirectoryTest
  *
  * @group DB
  *
  * @package Test\Files\Storage
  */
-class CopyDirectory extends Storage {
+class CopyDirectoryTest extends Storage {
 
 	protected function setUp() {
 		parent::setUp();
diff --git a/tests/lib/files/storage/homestoragequota.php b/tests/lib/Files/Storage/HomeStorageQuotaTest.php
similarity index 96%
rename from tests/lib/files/storage/homestoragequota.php
rename to tests/lib/Files/Storage/HomeStorageQuotaTest.php
index 9a3c6b151fce61b183acfeab9b8a3efdd9f0219f..68fa4bb0bbbfc719b04028a9ec8ba177ed96018b 100644
--- a/tests/lib/files/storage/homestoragequota.php
+++ b/tests/lib/Files/Storage/HomeStorageQuotaTest.php
@@ -22,11 +22,11 @@
 namespace Test\Files\Storage;
 
 /**
- * Class HomeStorageQuota
+ * Class HomeStorageQuotaTest
  *
  * @group DB
  */
-class HomeStorageQuota extends \Test\TestCase {
+class HomeStorageQuotaTest extends \Test\TestCase {
 	/**
 	 * Tests that the home storage is not wrapped when no quota exists.
 	 */
diff --git a/tests/lib/files/storage/home.php b/tests/lib/Files/Storage/HomeTest.php
similarity index 98%
rename from tests/lib/files/storage/home.php
rename to tests/lib/Files/Storage/HomeTest.php
index 1ed3b137cd405148367268f3e26fb272d86483cf..d9a1b11849e714a9c29e7818bc7327ebd6a3eff5 100644
--- a/tests/lib/files/storage/home.php
+++ b/tests/lib/Files/Storage/HomeTest.php
@@ -54,7 +54,7 @@ class DummyUser extends User {
  *
  * @package Test\Files\Storage
  */
-class Home extends Storage {
+class HomeTest extends Storage {
 	/**
 	 * @var string tmpDir
 	 */
diff --git a/tests/lib/files/storage/local.php b/tests/lib/Files/Storage/LocalTest.php
similarity index 97%
rename from tests/lib/files/storage/local.php
rename to tests/lib/Files/Storage/LocalTest.php
index 4cc6c6a842c34940513ed33d1f69ecbce74b6ed3..7b8ae6a24b27409904fd167dd8bc375a2aab1dba 100644
--- a/tests/lib/files/storage/local.php
+++ b/tests/lib/Files/Storage/LocalTest.php
@@ -23,13 +23,13 @@
 namespace Test\Files\Storage;
 
 /**
- * Class Local
+ * Class LocalTest
  *
  * @group DB
  *
  * @package Test\Files\Storage
  */
-class Local extends Storage {
+class LocalTest extends Storage {
 	/**
 	 * @var string tmpDir
 	 */
diff --git a/tests/lib/files/storage/storage.php b/tests/lib/Files/Storage/Storage.php
similarity index 100%
rename from tests/lib/files/storage/storage.php
rename to tests/lib/Files/Storage/Storage.php
diff --git a/tests/lib/files/storage/storagefactory.php b/tests/lib/Files/Storage/StorageFactoryTest.php
similarity index 98%
rename from tests/lib/files/storage/storagefactory.php
rename to tests/lib/Files/Storage/StorageFactoryTest.php
index fcdff577dd59519bd9a98b0b49ee2f9c7ef834c5..d3dc036ab429984eda15d4240cc34ab1b8ffec8c 100644
--- a/tests/lib/files/storage/storagefactory.php
+++ b/tests/lib/Files/Storage/StorageFactoryTest.php
@@ -25,7 +25,7 @@ class DummyWrapper extends Wrapper {
 	}
 }
 
-class StorageFactory extends TestCase {
+class StorageFactoryTest extends TestCase {
 	public function testSimpleWrapper() {
 		$instance = new \OC\Files\Storage\StorageFactory();
 		$mount = new MountPoint('\OC\Files\Storage\Temporary', '/foo', [[]], $instance);
diff --git a/tests/lib/files/storage/wrapper/availability.php b/tests/lib/Files/Storage/Wrapper/AvailabilityTest.php
similarity index 98%
rename from tests/lib/files/storage/wrapper/availability.php
rename to tests/lib/Files/Storage/Wrapper/AvailabilityTest.php
index 311334a80a3f83ddebfc46a3590e11a4fb828939..5ea7f8403ce7e1da3df2fe2e758850c85d9dd71e 100644
--- a/tests/lib/files/storage/wrapper/availability.php
+++ b/tests/lib/Files/Storage/Wrapper/AvailabilityTest.php
@@ -21,7 +21,7 @@
 
 namespace Test\Files\Storage\Wrapper;
 
-class Availability extends \Test\TestCase {
+class AvailabilityTest extends \Test\TestCase {
 	protected function getWrapperInstance() {
 		$storage = $this->getMockBuilder('\OC\Files\Storage\Temporary')
 			->disableOriginalConstructor()
diff --git a/tests/lib/files/storage/wrapper/encryption.php b/tests/lib/Files/Storage/Wrapper/EncryptionTest.php
similarity index 99%
rename from tests/lib/files/storage/wrapper/encryption.php
rename to tests/lib/Files/Storage/Wrapper/EncryptionTest.php
index 21f7d9f09b92d647bb82906ebebb499810381ed5..e9ebf2f3bdfbac93f45dd6067c2dbb78ba29b99c 100644
--- a/tests/lib/files/storage/wrapper/encryption.php
+++ b/tests/lib/Files/Storage/Wrapper/EncryptionTest.php
@@ -8,7 +8,7 @@ use OC\Files\View;
 use OC\User\Manager;
 use Test\Files\Storage\Storage;
 
-class Encryption extends Storage {
+class EncryptionTest extends Storage {
 
 	/**
 	 * block size will always be 8192 for a PHP stream
diff --git a/tests/lib/files/storage/wrapper/jail.php b/tests/lib/Files/Storage/Wrapper/JailTest.php
similarity index 96%
rename from tests/lib/files/storage/wrapper/jail.php
rename to tests/lib/Files/Storage/Wrapper/JailTest.php
index 9b16bc5a3213d3905b5276cdcb5713584463500b..b03eb0bcc63218a6adc8c39a7125a5b86440000b 100644
--- a/tests/lib/files/storage/wrapper/jail.php
+++ b/tests/lib/Files/Storage/Wrapper/JailTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Storage\Wrapper;
 
-class Jail extends \Test\Files\Storage\Storage {
+class JailTest extends \Test\Files\Storage\Storage {
 
 	/**
 	 * @var \OC\Files\Storage\Temporary
diff --git a/tests/lib/files/storage/wrapper/permissionsmask.php b/tests/lib/Files/Storage/Wrapper/PermissionsMaskTest.php
similarity index 98%
rename from tests/lib/files/storage/wrapper/permissionsmask.php
rename to tests/lib/Files/Storage/Wrapper/PermissionsMaskTest.php
index 7e8c387677cbe5413df6c5046e57d7d050cea03c..c3421553643b67c561b2fdc3f8b8ed797389c2a6 100644
--- a/tests/lib/files/storage/wrapper/permissionsmask.php
+++ b/tests/lib/Files/Storage/Wrapper/PermissionsMaskTest.php
@@ -10,7 +10,7 @@ namespace Test\Files\Storage\Wrapper;
 
 use OCP\Constants;
 
-class PermissionsMask extends \Test\Files\Storage\Storage {
+class PermissionsMaskTest extends \Test\Files\Storage\Storage {
 
 	/**
 	 * @var \OC\Files\Storage\Temporary
diff --git a/tests/lib/files/storage/wrapper/quota.php b/tests/lib/Files/Storage/Wrapper/QuotaTest.php
similarity index 98%
rename from tests/lib/files/storage/wrapper/quota.php
rename to tests/lib/Files/Storage/Wrapper/QuotaTest.php
index d087a3eef3340d91d79a16f3449e84d979e9e3f3..2e9f68b3c5611157791fd7d856356ddc2bb170f5 100644
--- a/tests/lib/files/storage/wrapper/quota.php
+++ b/tests/lib/Files/Storage/Wrapper/QuotaTest.php
@@ -14,13 +14,13 @@ use OC\Files\Cache\CacheEntry;
 \OC::$loader->load('\OC\Files\Filesystem');
 
 /**
- * Class Quota
+ * Class QuotaTest
  *
  * @group DB
  *
  * @package Test\Files\Storage\Wrapper
  */
-class Quota extends \Test\Files\Storage\Storage {
+class QuotaTest extends \Test\Files\Storage\Storage {
 	/**
 	 * @var string tmpDir
 	 */
diff --git a/tests/lib/files/storage/wrapper/wrapper.php b/tests/lib/Files/Storage/Wrapper/WrapperTest.php
similarity index 94%
rename from tests/lib/files/storage/wrapper/wrapper.php
rename to tests/lib/Files/Storage/Wrapper/WrapperTest.php
index a5a678cb9f754e30f1ffb3d0eccd6659b0b7e8ab..942ff27fc35ce63ac808ed5a2ac45630f6a45b98 100644
--- a/tests/lib/files/storage/wrapper/wrapper.php
+++ b/tests/lib/Files/Storage/Wrapper/WrapperTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Storage\Wrapper;
 
-class Wrapper extends \Test\Files\Storage\Storage {
+class WrapperTest extends \Test\Files\Storage\Storage {
 	/**
 	 * @var string tmpDir
 	 */
diff --git a/tests/lib/files/stream/dummyencryptionwrapper.php b/tests/lib/Files/Stream/DummyEncryptionWrapper.php
similarity index 100%
rename from tests/lib/files/stream/dummyencryptionwrapper.php
rename to tests/lib/Files/Stream/DummyEncryptionWrapper.php
diff --git a/tests/lib/files/stream/encryption.php b/tests/lib/Files/Stream/EncryptionTest.php
similarity index 99%
rename from tests/lib/files/stream/encryption.php
rename to tests/lib/Files/Stream/EncryptionTest.php
index 20a4100d2ff21a1a0621d3bd8fc01d6433bfe6ec..45204e48d09a7df801d52a5d213213f38c85d5ac 100644
--- a/tests/lib/files/stream/encryption.php
+++ b/tests/lib/Files/Stream/EncryptionTest.php
@@ -4,7 +4,7 @@ namespace Test\Files\Stream;
 
 use OC\Files\View;
 
-class Encryption extends \Test\TestCase {
+class EncryptionTest extends \Test\TestCase {
 
 	/** @var  \OCP\Encryption\IEncryptionModule | \PHPUnit_Framework_MockObject_MockObject  */
 	private $encryptionModule;
diff --git a/tests/lib/files/stream/quota.php b/tests/lib/Files/Stream/QuotaTest.php
similarity index 99%
rename from tests/lib/files/stream/quota.php
rename to tests/lib/Files/Stream/QuotaTest.php
index 28584cf82db2779aadac0a2fab6e14326b71df48..d084f0c769cacd951da862a932f586c6662f0fb6 100644
--- a/tests/lib/files/stream/quota.php
+++ b/tests/lib/Files/Stream/QuotaTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Stream;
 
-class Quota extends \Test\TestCase {
+class QuotaTest extends \Test\TestCase {
 	protected function tearDown() {
 		\OC\Files\Stream\Quota::clear();
 		parent::tearDown();
diff --git a/tests/lib/files/stream/staticstream.php b/tests/lib/Files/Stream/StaticStreamTest.php
similarity index 97%
rename from tests/lib/files/stream/staticstream.php
rename to tests/lib/Files/Stream/StaticStreamTest.php
index 416a4670efda724c5f34710da5441bd87fccda1c..309291a3a5b270439aba8cc30b1a220b3edcc614 100644
--- a/tests/lib/files/stream/staticstream.php
+++ b/tests/lib/Files/Stream/StaticStreamTest.php
@@ -8,7 +8,7 @@
 
 namespace Test\Files\Stream;
 
-class StaticStream extends \Test\TestCase {
+class StaticStreamTest extends \Test\TestCase {
 
 	private $sourceFile;
 	private $sourceText;
diff --git a/tests/lib/files/type/DetectionTest.php b/tests/lib/Files/Type/DetectionTest.php
similarity index 100%
rename from tests/lib/files/type/DetectionTest.php
rename to tests/lib/Files/Type/DetectionTest.php
diff --git a/tests/lib/files/type/loadertest.php b/tests/lib/Files/Type/LoaderTest.php
similarity index 100%
rename from tests/lib/files/type/loadertest.php
rename to tests/lib/Files/Type/LoaderTest.php
diff --git a/tests/lib/files/utils/scanner.php b/tests/lib/Files/Utils/ScannerTest.php
similarity index 98%
rename from tests/lib/files/utils/scanner.php
rename to tests/lib/Files/Utils/ScannerTest.php
index 1220c57e962853ee09d4301a56f4da4ed5182225..0c8e41c24c7ef705007c23e64e0d87a556b35c78 100644
--- a/tests/lib/files/utils/scanner.php
+++ b/tests/lib/Files/Utils/ScannerTest.php
@@ -33,13 +33,13 @@ class TestScanner extends \OC\Files\Utils\Scanner {
 }
 
 /**
- * Class Scanner
+ * Class ScannerTest
  *
  * @group DB
  *
  * @package Test\Files\Utils
  */
-class Scanner extends \Test\TestCase {
+class ScannerTest extends \Test\TestCase {
 	/**
 	 * @var \Test\Util\User\Dummy
 	 */
diff --git a/tests/lib/files/view.php b/tests/lib/Files/ViewTest.php
similarity index 99%
rename from tests/lib/files/view.php
rename to tests/lib/Files/ViewTest.php
index d33c9f3150323098cea26ae8aef937c858b22acd..2c27bb64a70ddd61f5ec4eb95c09cf746a432fec 100644
--- a/tests/lib/files/view.php
+++ b/tests/lib/Files/ViewTest.php
@@ -41,13 +41,13 @@ class TemporaryNoLocal extends \OC\Files\Storage\Temporary {
 }
 
 /**
- * Class View
+ * Class ViewTest
  *
  * @group DB
  *
  * @package Test\Files
  */
-class View extends \Test\TestCase {
+class ViewTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Files\Storage\Storage[] $storages
 	 */
diff --git a/tests/lib/files.php b/tests/lib/FilesTest.php
similarity index 99%
rename from tests/lib/files.php
rename to tests/lib/FilesTest.php
index 6808b3e9f645a609e0bb5ae46d681f5afbdd8355..b2a68c2a31bb226fc9b4770a8cc310b21c6f26a3 100644
--- a/tests/lib/files.php
+++ b/tests/lib/FilesTest.php
@@ -22,7 +22,7 @@
 
 namespace Test;
 
-class Files extends \Test\TestCase {
+class FilesTest extends \Test\TestCase {
 
 	const UPLOAD_LIMIT_DEFAULT_STR = '513M';
 	const UPLOAD_LIMIT_SETTING_STR = '2M';
diff --git a/tests/lib/group/backend.php b/tests/lib/Group/Backend.php
similarity index 99%
rename from tests/lib/group/backend.php
rename to tests/lib/Group/Backend.php
index 53a13e6c62fb8550d394b3d0c226b95a24c92417..eb17e9bded7f3a2d258c493c807e8703427b7861 100644
--- a/tests/lib/group/backend.php
+++ b/tests/lib/Group/Backend.php
@@ -27,7 +27,7 @@
 namespace Test\Group;
 
 /**
- * Class Test_Group_Backend
+ * Class Backend
  *
  * @group DB
  */
diff --git a/tests/lib/group/database.php b/tests/lib/Group/DatabaseTest.php
similarity index 97%
rename from tests/lib/group/database.php
rename to tests/lib/Group/DatabaseTest.php
index bf9d9c35b0bffdb4dd5874aa742ee37232d24d40..395a442c5e39c2cf4a9aa38a73962465b6dcf88a 100644
--- a/tests/lib/group/database.php
+++ b/tests/lib/Group/DatabaseTest.php
@@ -30,7 +30,7 @@ namespace Test\Group;
  *
  * @group DB
  */
-class Database extends Backend {
+class DatabaseTest extends Backend {
 	private $groups = array();
 
 	/**
diff --git a/tests/lib/group/dummy.php b/tests/lib/Group/Dummy.php
similarity index 100%
rename from tests/lib/group/dummy.php
rename to tests/lib/Group/Dummy.php
diff --git a/tests/lib/group/group.php b/tests/lib/Group/GroupTest.php
similarity index 99%
rename from tests/lib/group/group.php
rename to tests/lib/Group/GroupTest.php
index bf834ab23486115c6e3f0228b67e948b1a6b43a2..5ab8e41e4af37725cc52b7e2d774f2d9f22425d7 100644
--- a/tests/lib/group/group.php
+++ b/tests/lib/Group/GroupTest.php
@@ -11,7 +11,7 @@ namespace Test\Group;
 
 use OC\User\User;
 
-class Group extends \Test\TestCase {
+class GroupTest extends \Test\TestCase {
 	/**
 	 * @return \OC\User\Manager | \OC\User\Manager
 	 */
diff --git a/tests/lib/group/LegacyGroupTest.php b/tests/lib/Group/LegacyGroupTest.php
similarity index 100%
rename from tests/lib/group/LegacyGroupTest.php
rename to tests/lib/Group/LegacyGroupTest.php
diff --git a/tests/lib/group/manager.php b/tests/lib/Group/ManagerTest.php
similarity index 99%
rename from tests/lib/group/manager.php
rename to tests/lib/Group/ManagerTest.php
index 751f0d0ebd5523962b9b7e008a3fc1d1af111d2c..907f2b5945229d8fba24075b86dfbb5bef75595d 100644
--- a/tests/lib/group/manager.php
+++ b/tests/lib/Group/ManagerTest.php
@@ -11,7 +11,7 @@ namespace Test\Group;
 
 use OC\User\User;
 
-class Manager extends \Test\TestCase {
+class ManagerTest extends \Test\TestCase {
 	public function testGet() {
 		/**
 		 * @var \PHPUnit_Framework_MockObject_MockObject | \OC\Group\Backend $backend
diff --git a/tests/lib/group/metadatatest.php b/tests/lib/Group/MetaDataTest.php
similarity index 100%
rename from tests/lib/group/metadatatest.php
rename to tests/lib/Group/MetaDataTest.php
diff --git a/tests/lib/hookhelper.php b/tests/lib/HookHelper.php
similarity index 100%
rename from tests/lib/hookhelper.php
rename to tests/lib/HookHelper.php
diff --git a/tests/lib/hooks/basicemitter.php b/tests/lib/Hooks/BasicEmitterTest.php
similarity index 98%
rename from tests/lib/hooks/basicemitter.php
rename to tests/lib/Hooks/BasicEmitterTest.php
index 899d3ecd3b3eb4cb3190b9ab30e687ef77c212f7..2e6bd8100e356b3b4aedfb55585abd3c61c6c321 100644
--- a/tests/lib/hooks/basicemitter.php
+++ b/tests/lib/Hooks/BasicEmitterTest.php
@@ -31,7 +31,7 @@ class DummyEmitter extends \OC\Hooks\BasicEmitter {
 class EmittedException extends \Exception {
 }
 
-class BasicEmitter extends \Test\TestCase {
+class BasicEmitterTest extends \Test\TestCase {
 	/**
 	 * @var \OC\Hooks\Emitter $emitter
 	 */
@@ -64,7 +64,7 @@ class BasicEmitter extends \Test\TestCase {
 	 * @expectedException \Test\Hooks\EmittedException
 	 */
 	public function testStaticCallback() {
-		$this->emitter->listen('Test', 'test', array('\Test\Hooks\BasicEmitter', 'staticCallBack'));
+		$this->emitter->listen('Test', 'test', array('\Test\Hooks\BasicEmitterTest', 'staticCallBack'));
 		$this->emitter->emitEvent('Test', 'test');
 	}
 
diff --git a/tests/lib/hooks/forwardingemitter.php b/tests/lib/Hooks/ForwardingEmitterTest.php
similarity index 97%
rename from tests/lib/hooks/forwardingemitter.php
rename to tests/lib/Hooks/ForwardingEmitterTest.php
index 5e8e252d3e3d6cd58532c832a4c5ecef0b8fe4d1..ea8ee5c412130817c8a9af5c33847fbb51d792b6 100644
--- a/tests/lib/hooks/forwardingemitter.php
+++ b/tests/lib/Hooks/ForwardingEmitterTest.php
@@ -29,7 +29,7 @@ class DummyForwardingEmitter extends \OC\Hooks\ForwardingEmitter {
  *
  * @package OC\Hooks
  */
-class ForwardingEmitter extends BasicEmitter {
+class ForwardingEmitterTest extends BasicEmitterTest {
 	public function testSingleForward() {
 		$baseEmitter = new PublicEmitter();
 		$forwardingEmitter = new DummyForwardingEmitter();
diff --git a/tests/lib/hooks/legacyemitter.php b/tests/lib/Hooks/LegacyEmitterTest.php
similarity index 84%
rename from tests/lib/hooks/legacyemitter.php
rename to tests/lib/Hooks/LegacyEmitterTest.php
index f030afbc09025ac532bac0c44435d3f454f0059c..60a29f23245a63856db135a9af405a5f10746134 100644
--- a/tests/lib/hooks/legacyemitter.php
+++ b/tests/lib/Hooks/LegacyEmitterTest.php
@@ -21,7 +21,7 @@ class DummyLegacyEmitter extends \OC\Hooks\LegacyEmitter {
 	}
 }
 
-class LegacyEmitter extends BasicEmitter {
+class LegacyEmitterTest extends BasicEmitterTest {
 
 	//we can't use exceptions here since OC_Hooks catches all exceptions
 	private static $emitted = false;
@@ -44,13 +44,13 @@ class LegacyEmitter extends BasicEmitter {
 	}
 
 	public function testLegacyHook() {
-		\OC_Hook::connect('Test', 'test', '\Test\Hooks\LegacyEmitter', 'staticLegacyCallBack');
+		\OC_Hook::connect('Test', 'test', '\Test\Hooks\LegacyEmitterTest', 'staticLegacyCallBack');
 		$this->emitter->emitEvent('Test', 'test');
 		$this->assertEquals(true, self::$emitted);
 	}
 
 	public function testLegacyArguments() {
-		\OC_Hook::connect('Test', 'test', '\Test\Hooks\LegacyEmitter', 'staticLegacyArgumentsCallBack');
+		\OC_Hook::connect('Test', 'test', '\Test\Hooks\LegacyEmitterTest', 'staticLegacyArgumentsCallBack');
 		$this->emitter->emitEvent('Test', 'test', array('foo' => 'foo', 'bar' => 'bar'));
 		$this->assertEquals(true, self::$emitted);
 	}
diff --git a/tests/lib/http/client/clientservicetest.php b/tests/lib/Http/Client/ClientServiceTest.php
similarity index 100%
rename from tests/lib/http/client/clientservicetest.php
rename to tests/lib/Http/Client/ClientServiceTest.php
diff --git a/tests/lib/http/client/clienttest.php b/tests/lib/Http/Client/ClientTest.php
similarity index 100%
rename from tests/lib/http/client/clienttest.php
rename to tests/lib/Http/Client/ClientTest.php
diff --git a/tests/lib/http/client/responsetest.php b/tests/lib/Http/Client/ResponseTest.php
similarity index 100%
rename from tests/lib/http/client/responsetest.php
rename to tests/lib/Http/Client/ResponseTest.php
diff --git a/tests/lib/integritycheck/checkertest.php b/tests/lib/IntegrityCheck/CheckerTest.php
similarity index 100%
rename from tests/lib/integritycheck/checkertest.php
rename to tests/lib/IntegrityCheck/CheckerTest.php
diff --git a/tests/lib/integritycheck/helpers/AppLocatorTest.php b/tests/lib/IntegrityCheck/Helpers/AppLocatorTest.php
similarity index 100%
rename from tests/lib/integritycheck/helpers/AppLocatorTest.php
rename to tests/lib/IntegrityCheck/Helpers/AppLocatorTest.php
diff --git a/tests/lib/integritycheck/helpers/EnvironmentHelperTest.php b/tests/lib/IntegrityCheck/Helpers/EnvironmentHelperTest.php
similarity index 100%
rename from tests/lib/integritycheck/helpers/EnvironmentHelperTest.php
rename to tests/lib/IntegrityCheck/Helpers/EnvironmentHelperTest.php
diff --git a/tests/lib/integritycheck/helpers/FileAccessHelperTest.php b/tests/lib/IntegrityCheck/Helpers/FileAccessHelperTest.php
similarity index 100%
rename from tests/lib/integritycheck/helpers/FileAccessHelperTest.php
rename to tests/lib/IntegrityCheck/Helpers/FileAccessHelperTest.php
diff --git a/tests/lib/l10n/factorytest.php b/tests/lib/L10N/FactoryTest.php
similarity index 100%
rename from tests/lib/l10n/factorytest.php
rename to tests/lib/L10N/FactoryTest.php
diff --git a/tests/lib/l10n/l10nlegacytest.php b/tests/lib/L10N/L10nLegacyTest.php
similarity index 100%
rename from tests/lib/l10n/l10nlegacytest.php
rename to tests/lib/L10N/L10nLegacyTest.php
diff --git a/tests/lib/l10n/l10ntest.php b/tests/lib/L10N/L10nTest.php
similarity index 100%
rename from tests/lib/l10n/l10ntest.php
rename to tests/lib/L10N/L10nTest.php
diff --git a/tests/lib/largefilehelpergetfilesize.php b/tests/lib/LargeFileHelperGetFileSizeTest.php
similarity index 97%
rename from tests/lib/largefilehelpergetfilesize.php
rename to tests/lib/LargeFileHelperGetFileSizeTest.php
index 57bc23819668baf106e4935ff2b82f1d8dbe6955..ac81a31819f5ce60028919c5b29b1b2b6ab4545f 100644
--- a/tests/lib/largefilehelpergetfilesize.php
+++ b/tests/lib/LargeFileHelperGetFileSizeTest.php
@@ -12,7 +12,7 @@ namespace Test;
 * Tests whether LargeFileHelper is able to determine file size at all.
 * Large files are not considered yet.
 */
-class LargeFileHelperGetFileSize extends TestCase {
+class LargeFileHelperGetFileSizeTest extends TestCase {
 	/** @var string */
 	protected $filename;
 	/** @var int */
diff --git a/tests/lib/largefilehelper.php b/tests/lib/LargeFileHelperTest.php
similarity index 95%
rename from tests/lib/largefilehelper.php
rename to tests/lib/LargeFileHelperTest.php
index 1267a8c5833901c524148932261ae922a6fd292a..7d155ff8b4475ea140ddedf8efc203806e718dc7 100644
--- a/tests/lib/largefilehelper.php
+++ b/tests/lib/LargeFileHelperTest.php
@@ -8,7 +8,7 @@
 
 namespace Test;
 
-class LargeFileHelper extends TestCase {
+class LargeFileHelperTest extends TestCase {
 	protected $helper;
 
 	protected function setUp() {
diff --git a/tests/lib/lock/dblockingprovider.php b/tests/lib/Lock/DBLockingProviderTest.php
similarity index 97%
rename from tests/lib/lock/dblockingprovider.php
rename to tests/lib/Lock/DBLockingProviderTest.php
index 743dbf85613bde238c51db2109b777945b72fe88..a7c3f4631554b3566e476537135c4e3616b96cfb 100644
--- a/tests/lib/lock/dblockingprovider.php
+++ b/tests/lib/Lock/DBLockingProviderTest.php
@@ -30,7 +30,7 @@ use OCP\Lock\ILockingProvider;
  *
  * @package Test\Lock
  */
-class DBLockingProvider extends LockingProvider {
+class DBLockingProviderTest extends LockingProvider {
 	/**
 	 * @var \OC\Lock\DBLockingProvider
 	 */
diff --git a/tests/lib/lock/lockingprovider.php b/tests/lib/Lock/LockingProvider.php
similarity index 100%
rename from tests/lib/lock/lockingprovider.php
rename to tests/lib/Lock/LockingProvider.php
diff --git a/tests/lib/lock/memcachelockingprovider.php b/tests/lib/Lock/MemcacheLockingProviderTest.php
similarity index 94%
rename from tests/lib/lock/memcachelockingprovider.php
rename to tests/lib/Lock/MemcacheLockingProviderTest.php
index 40478b22939e4d5bc7c7e9d37f95f98011f41bd3..baf99dbb2bbffd5ca275b90894bf799e64b350e2 100644
--- a/tests/lib/lock/memcachelockingprovider.php
+++ b/tests/lib/Lock/MemcacheLockingProviderTest.php
@@ -23,7 +23,7 @@ namespace Test\Lock;
 
 use OC\Memcache\ArrayCache;
 
-class MemcacheLockingProvider extends LockingProvider {
+class MemcacheLockingProviderTest extends LockingProvider {
 
 	/**
 	 * @var \OCP\IMemcache
diff --git a/tests/lib/log/OwncloudTest.php b/tests/lib/Log/OwncloudTest.php
similarity index 100%
rename from tests/lib/log/OwncloudTest.php
rename to tests/lib/Log/OwncloudTest.php
diff --git a/tests/lib/logger.php b/tests/lib/LoggerTest.php
similarity index 97%
rename from tests/lib/logger.php
rename to tests/lib/LoggerTest.php
index e6a0abfbf28d56df446404843eda599873d605fe..4eb04b00f585996185a6b49330ff7b2789c737f3 100644
--- a/tests/lib/logger.php
+++ b/tests/lib/LoggerTest.php
@@ -10,7 +10,7 @@ namespace Test;
 
 use OC\Log;
 
-class Logger extends TestCase {
+class LoggerTest extends TestCase {
 	/**
 	 * @var \OCP\ILogger
 	 */
@@ -25,7 +25,7 @@ class Logger extends TestCase {
 			'\OC\SystemConfig')
 			->disableOriginalConstructor()
 			->getMock();
-		$this->logger = new Log('Test\Logger', $this->config);
+		$this->logger = new Log('Test\LoggerTest', $this->config);
 	}
 
 	public function testInterpolation() {
diff --git a/tests/lib/mail/MailerTest.php b/tests/lib/Mail/MailerTest.php
similarity index 100%
rename from tests/lib/mail/MailerTest.php
rename to tests/lib/Mail/MailerTest.php
diff --git a/tests/lib/mail/MessageTest.php b/tests/lib/Mail/MessageTest.php
similarity index 100%
rename from tests/lib/mail/MessageTest.php
rename to tests/lib/Mail/MessageTest.php
diff --git a/tests/lib/memcache/apc.php b/tests/lib/Memcache/APCTest.php
similarity index 95%
rename from tests/lib/memcache/apc.php
rename to tests/lib/Memcache/APCTest.php
index fdb785b9dc5ab126d94e2347564db31687731872..4bd7e62b94a2effe9b4259bef4b27d977ca67cf7 100644
--- a/tests/lib/memcache/apc.php
+++ b/tests/lib/Memcache/APCTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class APC extends Cache {
+class APCTest extends Cache {
 	protected function setUp() {
 		parent::setUp();
 
diff --git a/tests/lib/memcache/apcu.php b/tests/lib/Memcache/APCuTest.php
similarity index 93%
rename from tests/lib/memcache/apcu.php
rename to tests/lib/Memcache/APCuTest.php
index afcaa99bfbeccb05deb1cb093462baaa657ab46c..73fd5a12880c95f8291c67350a8867701933e465 100644
--- a/tests/lib/memcache/apcu.php
+++ b/tests/lib/Memcache/APCuTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class APCu extends Cache {
+class APCuTest extends Cache {
 	protected function setUp() {
 		parent::setUp();
 
diff --git a/tests/lib/memcache/arraycache.php b/tests/lib/Memcache/ArrayCacheTest.php
similarity index 90%
rename from tests/lib/memcache/arraycache.php
rename to tests/lib/Memcache/ArrayCacheTest.php
index 1db673da2a890fb0a8771150572b2e3334a40643..3ae8c116a01b9465d6f19d1d6a9443bb230afe70 100644
--- a/tests/lib/memcache/arraycache.php
+++ b/tests/lib/Memcache/ArrayCacheTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class ArrayCache extends Cache {
+class ArrayCacheTest extends Cache {
 	protected function setUp() {
 		parent::setUp();
 		$this->instance = new \OC\Memcache\ArrayCache('');
diff --git a/tests/lib/memcache/cache.php b/tests/lib/Memcache/Cache.php
similarity index 100%
rename from tests/lib/memcache/cache.php
rename to tests/lib/Memcache/Cache.php
diff --git a/tests/lib/memcache/castrait.php b/tests/lib/Memcache/CasTraitTest.php
similarity index 98%
rename from tests/lib/memcache/castrait.php
rename to tests/lib/Memcache/CasTraitTest.php
index 17f412bb638440e8ec3704933b5ea0aabc43a88e..2f0ef939aa706448625bafa6cd90fd67d25ab59e 100644
--- a/tests/lib/memcache/castrait.php
+++ b/tests/lib/Memcache/CasTraitTest.php
@@ -23,7 +23,7 @@ namespace Test\Memcache;
 
 use Test\TestCase;
 
-class CasTrait extends TestCase {
+class CasTraitTest extends TestCase {
 	/**
 	 * @return \OC\Memcache\CasTrait
 	 */
diff --git a/tests/lib/memcache/FactoryTest.php b/tests/lib/Memcache/FactoryTest.php
similarity index 100%
rename from tests/lib/memcache/FactoryTest.php
rename to tests/lib/Memcache/FactoryTest.php
diff --git a/tests/lib/memcache/memcached.php b/tests/lib/Memcache/MemcachedTest.php
similarity index 97%
rename from tests/lib/memcache/memcached.php
rename to tests/lib/Memcache/MemcachedTest.php
index 3ea9216029a4d69fc4af1b8bd1277b6503cf04bb..865d8594bbbd57939c48ae253e99dd27c2a1c925 100644
--- a/tests/lib/memcache/memcached.php
+++ b/tests/lib/Memcache/MemcachedTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class Memcached extends Cache {
+class MemcachedTest extends Cache {
 	static public function setUpBeforeClass() {
 		parent::setUpBeforeClass();
 
diff --git a/tests/lib/memcache/redis.php b/tests/lib/Memcache/RedisTest.php
similarity index 96%
rename from tests/lib/memcache/redis.php
rename to tests/lib/Memcache/RedisTest.php
index 2e3c5d735fe16db31bdbe984c56db939065b078c..094954d4a1a04ec69f5b6eae2ca1741a6012a3a3 100644
--- a/tests/lib/memcache/redis.php
+++ b/tests/lib/Memcache/RedisTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class Redis extends Cache {
+class RedisTest extends Cache {
 	static public function setUpBeforeClass() {
 		parent::setUpBeforeClass();
 
diff --git a/tests/lib/memcache/xcache.php b/tests/lib/Memcache/XCacheTest.php
similarity index 93%
rename from tests/lib/memcache/xcache.php
rename to tests/lib/Memcache/XCacheTest.php
index 36efe0b220a51abe0e38cf421cd594627a2a9c8a..af720115d0141d675b917280fd05e1af124ee445 100644
--- a/tests/lib/memcache/xcache.php
+++ b/tests/lib/Memcache/XCacheTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Memcache;
 
-class XCache extends Cache {
+class XCacheTest extends Cache {
 	protected function setUp() {
 		parent::setUp();
 
diff --git a/tests/lib/migration/BackgroundRepairTest.php b/tests/lib/Migration/BackgroundRepairTest.php
similarity index 100%
rename from tests/lib/migration/BackgroundRepairTest.php
rename to tests/lib/Migration/BackgroundRepairTest.php
diff --git a/tests/lib/navigationmanagertest.php b/tests/lib/NavigationManagerTest.php
similarity index 100%
rename from tests/lib/navigationmanagertest.php
rename to tests/lib/NavigationManagerTest.php
diff --git a/tests/lib/notification/actiontest.php b/tests/lib/Notification/ActionTest.php
similarity index 100%
rename from tests/lib/notification/actiontest.php
rename to tests/lib/Notification/ActionTest.php
diff --git a/tests/lib/notification/managertest.php b/tests/lib/Notification/ManagerTest.php
similarity index 100%
rename from tests/lib/notification/managertest.php
rename to tests/lib/Notification/ManagerTest.php
diff --git a/tests/lib/notification/notificationtest.php b/tests/lib/Notification/NotificationTest.php
similarity index 100%
rename from tests/lib/notification/notificationtest.php
rename to tests/lib/Notification/NotificationTest.php
diff --git a/tests/lib/ocs/MapStatusCodeTest.php b/tests/lib/OCS/MapStatusCodeTest.php
similarity index 100%
rename from tests/lib/ocs/MapStatusCodeTest.php
rename to tests/lib/OCS/MapStatusCodeTest.php
diff --git a/tests/lib/ocs/PrivatedataTest.php b/tests/lib/OCS/PrivatedataTest.php
similarity index 100%
rename from tests/lib/ocs/PrivatedataTest.php
rename to tests/lib/OCS/PrivatedataTest.php
diff --git a/tests/lib/ocs/ProviderTest.php b/tests/lib/OCS/ProviderTest.php
similarity index 100%
rename from tests/lib/ocs/ProviderTest.php
rename to tests/lib/OCS/ProviderTest.php
diff --git a/tests/lib/ocsclienttest.php b/tests/lib/OCSClientTest.php
similarity index 100%
rename from tests/lib/ocsclienttest.php
rename to tests/lib/OCSClientTest.php
diff --git a/tests/lib/preview/bitmap.php b/tests/lib/Preview/BitmapTest.php
similarity index 95%
rename from tests/lib/preview/bitmap.php
rename to tests/lib/Preview/BitmapTest.php
index 1e135ceb08317673ef47a5c2a4bb1ea5f4b64d61..32d6ce896e4c43537f23cbb317ccbf6cda226401 100644
--- a/tests/lib/preview/bitmap.php
+++ b/tests/lib/Preview/BitmapTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class Bitmap
+ * Class BitmapTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class Bitmap extends Provider {
+class BitmapTest extends Provider {
 
 	public function setUp() {
 		parent::setUp();
diff --git a/tests/lib/preview/image.php b/tests/lib/Preview/ImageTest.php
similarity index 95%
rename from tests/lib/preview/image.php
rename to tests/lib/Preview/ImageTest.php
index 6c82ff85723cd0700996ab33ab30aa89b9bf0308..a55433a2682efdb8382be37386022752a2227a4e 100644
--- a/tests/lib/preview/image.php
+++ b/tests/lib/Preview/ImageTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class Image
+ * Class ImageTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class Image extends Provider {
+class ImageTest extends Provider {
 
 	public function setUp() {
 		parent::setUp();
diff --git a/tests/lib/preview/mp3.php b/tests/lib/Preview/MP3Test.php
similarity index 95%
rename from tests/lib/preview/mp3.php
rename to tests/lib/Preview/MP3Test.php
index f6875a88ebde3eb18a12ebc0c576fcae7a3e5e97..576eea20b8bd438d3aba9e5814a8e52e31fa69e1 100644
--- a/tests/lib/preview/mp3.php
+++ b/tests/lib/Preview/MP3Test.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class MP3
+ * Class MP3Test
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class MP3 extends Provider {
+class MP3Test extends Provider {
 
 	public function setUp() {
 		parent::setUp();
diff --git a/tests/lib/preview/movie.php b/tests/lib/Preview/MovieTest.php
similarity index 96%
rename from tests/lib/preview/movie.php
rename to tests/lib/Preview/MovieTest.php
index 0ad8c13fc634d6cac9bc13e5ec196b6f1b2f9b6b..0c174a40ca62f3d70ed356e8bf82e78b18a423af 100644
--- a/tests/lib/preview/movie.php
+++ b/tests/lib/Preview/MovieTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class Movie
+ * Class MovieTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class Movie extends Provider {
+class MovieTest extends Provider {
 
 	public function setUp() {
 		$avconvBinary = \OC_Helper::findBinaryPath('avconv');
diff --git a/tests/lib/preview/office.php b/tests/lib/Preview/OfficeTest.php
similarity index 96%
rename from tests/lib/preview/office.php
rename to tests/lib/Preview/OfficeTest.php
index 83eb5e2cecbe28cc7fc9b411ffd2455a77bdf8a5..15d66352c185152852de5d96da12e3a8c954340d 100644
--- a/tests/lib/preview/office.php
+++ b/tests/lib/Preview/OfficeTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class Office
+ * Class OfficeTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class Office extends Provider {
+class OfficeTest extends Provider {
 
 	public function setUp() {
 		$libreofficeBinary = \OC_Helper::findBinaryPath('libreoffice');
diff --git a/tests/lib/preview/provider.php b/tests/lib/Preview/Provider.php
similarity index 100%
rename from tests/lib/preview/provider.php
rename to tests/lib/Preview/Provider.php
diff --git a/tests/lib/preview/svg.php b/tests/lib/Preview/SVGTest.php
similarity index 96%
rename from tests/lib/preview/svg.php
rename to tests/lib/Preview/SVGTest.php
index ef5f4cff80fb8a94eed64cd248cdef39b38057e4..39bf3f1dfc9eb84760c44934746496421edd786a 100644
--- a/tests/lib/preview/svg.php
+++ b/tests/lib/Preview/SVGTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class SVG
+ * Class SVGTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class SVG extends Provider {
+class SVGTest extends Provider {
 
 	public function setUp() {
 		$checkImagick = new \Imagick();
diff --git a/tests/lib/preview/txt.php b/tests/lib/Preview/TXTTest.php
similarity index 95%
rename from tests/lib/preview/txt.php
rename to tests/lib/Preview/TXTTest.php
index 219b850be95401fd80558a89d1792ffc522cbac7..dfa0b920e1659b4076a3afca0b547cf0a34a5f64 100644
--- a/tests/lib/preview/txt.php
+++ b/tests/lib/Preview/TXTTest.php
@@ -22,13 +22,13 @@
 namespace Test\Preview;
 
 /**
- * Class TXT
+ * Class TXTTest
  *
  * @group DB
  *
  * @package Test\Preview
  */
-class TXT extends Provider {
+class TXTTest extends Provider {
 
 	public function setUp() {
 		parent::setUp();
diff --git a/tests/lib/preview.php b/tests/lib/PreviewTest.php
similarity index 99%
rename from tests/lib/preview.php
rename to tests/lib/PreviewTest.php
index bc6f849cbe8333b122583fcde998fdc21d176a07..6ca88253468f018a9e3de3c96fea9a270f7493f5 100644
--- a/tests/lib/preview.php
+++ b/tests/lib/PreviewTest.php
@@ -29,13 +29,13 @@ use Test\Traits\MountProviderTrait;
 use Test\Traits\UserTrait;
 
 /**
- * Class Preview
+ * Class PreviewTest
  *
  * @group DB
  *
  * @package Test
  */
-class Preview extends TestCase {
+class PreviewTest extends TestCase {
 	use UserTrait;
 	use MountProviderTrait;
 
diff --git a/tests/lib/publicnamespace/ContactsTest.php b/tests/lib/PublicNamespace/ContactsTest.php
similarity index 100%
rename from tests/lib/publicnamespace/ContactsTest.php
rename to tests/lib/PublicNamespace/ContactsTest.php
diff --git a/tests/lib/publicnamespace/OCPConfigTest.php b/tests/lib/PublicNamespace/OCPConfigTest.php
similarity index 100%
rename from tests/lib/publicnamespace/OCPConfigTest.php
rename to tests/lib/PublicNamespace/OCPConfigTest.php
diff --git a/tests/lib/publicnamespace/UtilTest.php b/tests/lib/PublicNamespace/UtilTest.php
similarity index 100%
rename from tests/lib/publicnamespace/UtilTest.php
rename to tests/lib/PublicNamespace/UtilTest.php
diff --git a/tests/lib/repair/cleantags.php b/tests/lib/Repair/CleanTagsTest.php
similarity index 99%
rename from tests/lib/repair/cleantags.php
rename to tests/lib/Repair/CleanTagsTest.php
index 214e2a17c9419bf21e55be787e92a689e2185f29..804fa4f66c9318dad1ba34ccbe76e999a487a28e 100644
--- a/tests/lib/repair/cleantags.php
+++ b/tests/lib/Repair/CleanTagsTest.php
@@ -17,7 +17,7 @@ use OCP\Migration\IOutput;
  *
  * @see \OC\Repair\CleanTags
  */
-class CleanTags extends \Test\TestCase {
+class CleanTagsTest extends \Test\TestCase {
 
 	/** @var \OC\Repair\CleanTags */
 	protected $repair;
diff --git a/tests/lib/repair/dropoldjobs.php b/tests/lib/Repair/DropOldJobsTest.php
similarity index 97%
rename from tests/lib/repair/dropoldjobs.php
rename to tests/lib/Repair/DropOldJobsTest.php
index c8a4aa3f1c2565fcb31d1c25d95f805106ca410d..d83ecbe59c4f7ec040bf13d6d6cc3f486071454a 100644
--- a/tests/lib/repair/dropoldjobs.php
+++ b/tests/lib/Repair/DropOldJobsTest.php
@@ -18,7 +18,7 @@ use OCP\Migration\IOutput;
  *
  * @see \OC\Repair\DropOldTables
  */
-class DropOldJobs extends \Test\TestCase {
+class DropOldJobsTest extends \Test\TestCase {
 	/** @var IJobList */
 	protected $jobList;
 
diff --git a/tests/lib/repair/dropoldtables.php b/tests/lib/Repair/DropOldTablesTest.php
similarity index 96%
rename from tests/lib/repair/dropoldtables.php
rename to tests/lib/Repair/DropOldTablesTest.php
index d2e1d7c3449fe1d0247cabf22a04f8243a9ad5b5..1f5a4c15295304f9c806f2ed969ec47c6a536eca 100644
--- a/tests/lib/repair/dropoldtables.php
+++ b/tests/lib/Repair/DropOldTablesTest.php
@@ -16,7 +16,7 @@ use OCP\Migration\IOutput;
  *
  * @see \OC\Repair\DropOldTables
  */
-class DropOldTables extends \Test\TestCase {
+class DropOldTablesTest extends \Test\TestCase {
 	/** @var \OCP\IDBConnection */
 	protected $connection;
 
diff --git a/tests/lib/repair/oldgroupmembershipsharestest.php b/tests/lib/Repair/OldGroupMembershipSharesTest.php
similarity index 100%
rename from tests/lib/repair/oldgroupmembershipsharestest.php
rename to tests/lib/Repair/OldGroupMembershipSharesTest.php
diff --git a/tests/lib/repair/removegetetagentriestest.php b/tests/lib/Repair/RemoveGetETagEntriesTest.php
similarity index 100%
rename from tests/lib/repair/removegetetagentriestest.php
rename to tests/lib/Repair/RemoveGetETagEntriesTest.php
diff --git a/tests/lib/repair/RepairCollationTest.php b/tests/lib/Repair/RepairCollationTest.php
similarity index 100%
rename from tests/lib/repair/RepairCollationTest.php
rename to tests/lib/Repair/RepairCollationTest.php
diff --git a/tests/lib/repair/repairinnodb.php b/tests/lib/Repair/RepairInnoDBTest.php
similarity index 97%
rename from tests/lib/repair/repairinnodb.php
rename to tests/lib/Repair/RepairInnoDBTest.php
index 9b02bc46e29173385cac26e81fdf1989b1e06cad..1258dad73f53286202900383ae6e7ae665af8754 100644
--- a/tests/lib/repair/repairinnodb.php
+++ b/tests/lib/Repair/RepairInnoDBTest.php
@@ -16,7 +16,7 @@ use OCP\Migration\IRepairStep;
  *
  * @see \OC\Repair\RepairMimeTypes
  */
-class RepairInnoDB extends \Test\TestCase {
+class RepairInnoDBTest extends \Test\TestCase {
 
 	/** @var IRepairStep */
 	private $repair;
diff --git a/tests/lib/repair/repairinvalidsharestest.php b/tests/lib/Repair/RepairInvalidSharesTest.php
similarity index 100%
rename from tests/lib/repair/repairinvalidsharestest.php
rename to tests/lib/Repair/RepairInvalidSharesTest.php
diff --git a/tests/lib/repair/repairlegacystorage.php b/tests/lib/Repair/RepairLegacyStoragesTest.php
similarity index 99%
rename from tests/lib/repair/repairlegacystorage.php
rename to tests/lib/Repair/RepairLegacyStoragesTest.php
index 5b560458e769d80e9e4c0a15b320fb7e20210c9b..aa51fe06a3563291c0859ed307067e95b1c20b94 100644
--- a/tests/lib/repair/repairlegacystorage.php
+++ b/tests/lib/Repair/RepairLegacyStoragesTest.php
@@ -21,7 +21,7 @@ use Test\TestCase;
  *
  * @see \OC\Repair\RepairLegacyStorages
  */
-class RepairLegacyStorages extends TestCase {
+class RepairLegacyStoragesTest extends TestCase {
 	/** @var \OCP\IDBConnection */
 	private $connection;
 	/** @var \OCP\IConfig */
diff --git a/tests/lib/repair/repairmimetypes.php b/tests/lib/Repair/RepairMimeTypesTest.php
similarity index 99%
rename from tests/lib/repair/repairmimetypes.php
rename to tests/lib/Repair/RepairMimeTypesTest.php
index d8ef95e954692adc9fe5196283d0c21d9c520eda..6a42b01693876c30d3fe11b432867745b39b98ba 100644
--- a/tests/lib/repair/repairmimetypes.php
+++ b/tests/lib/Repair/RepairMimeTypesTest.php
@@ -21,7 +21,7 @@ use OCP\Migration\IRepairStep;
  *
  * @see \OC\Repair\RepairMimeTypes
  */
-class RepairMimeTypes extends \Test\TestCase {
+class RepairMimeTypesTest extends \Test\TestCase {
 
 	/** @var IRepairStep */
 	private $repair;
diff --git a/tests/lib/repair/repairsharepropagation.php b/tests/lib/Repair/RepairSharePropagationTest.php
similarity index 96%
rename from tests/lib/repair/repairsharepropagation.php
rename to tests/lib/Repair/RepairSharePropagationTest.php
index 34b47397a53ef07979e676ad40a2d8a39dbbefae..07db3c84f286917dadc881dd002ef7f85d49a8f5 100644
--- a/tests/lib/repair/repairsharepropagation.php
+++ b/tests/lib/Repair/RepairSharePropagationTest.php
@@ -11,7 +11,7 @@ namespace Test\Repair;
 use OC\Repair\SharePropagation;
 use OCP\Migration\IOutput;
 
-class RepairSharePropagation extends \Test\TestCase {
+class RepairSharePropagationTest extends \Test\TestCase {
 	public function keyProvider() {
 		return [
 			[['1', '2'], ['1', '2']],
diff --git a/tests/lib/repair/repairsqliteautoincrement.php b/tests/lib/Repair/RepairSqliteAutoincrementTest.php
similarity index 97%
rename from tests/lib/repair/repairsqliteautoincrement.php
rename to tests/lib/Repair/RepairSqliteAutoincrementTest.php
index 581857ebfc99b9014a4222bf9c84e03525f159cc..22186283779fa7810e8a8c172c6fb549741162a5 100644
--- a/tests/lib/repair/repairsqliteautoincrement.php
+++ b/tests/lib/Repair/RepairSqliteAutoincrementTest.php
@@ -14,7 +14,7 @@ use OCP\Migration\IOutput;
  *
  * @group DB
  */
-class RepairSqliteAutoincrement extends \Test\TestCase {
+class RepairSqliteAutoincrementTest extends \Test\TestCase {
 
 	/**
 	 * @var \OC\Repair\SqliteAutoincrement
diff --git a/tests/lib/repair/updateoutdatedocsids.php b/tests/lib/Repair/UpdateOutdatedOcsIdsTest.php
similarity index 97%
rename from tests/lib/repair/updateoutdatedocsids.php
rename to tests/lib/Repair/UpdateOutdatedOcsIdsTest.php
index 06e2cb1d610bf5a3a38fde6d0f68c55eb5cda737..eb80e63a202ce160f2d49baa6b259bc63ff3cbb0 100644
--- a/tests/lib/repair/updateoutdatedocsids.php
+++ b/tests/lib/Repair/UpdateOutdatedOcsIdsTest.php
@@ -29,7 +29,7 @@ use Test\TestCase;
  *
  * @package Test\Repair
  */
-class UpdateOutdatedOcsIds extends TestCase {
+class UpdateOutdatedOcsIdsTest extends TestCase {
 	/** @var IConfig | \PHPUnit_Framework_MockObject_MockObject */
 	private $config;
 	/** @var \OC\Repair\UpdateOutdatedOcsIds */
diff --git a/tests/lib/repair/fixtures/dropoldtables.xml b/tests/lib/Repair/fixtures/dropoldtables.xml
similarity index 100%
rename from tests/lib/repair/fixtures/dropoldtables.xml
rename to tests/lib/Repair/fixtures/dropoldtables.xml
diff --git a/tests/lib/security/csp/ContentSecurityPolicyManagerTest.php b/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
similarity index 100%
rename from tests/lib/security/csp/ContentSecurityPolicyManagerTest.php
rename to tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
diff --git a/tests/lib/security/csrf/CsrfTokenGeneratorTest.php b/tests/lib/Security/CSRF/CsrfTokenGeneratorTest.php
similarity index 100%
rename from tests/lib/security/csrf/CsrfTokenGeneratorTest.php
rename to tests/lib/Security/CSRF/CsrfTokenGeneratorTest.php
diff --git a/tests/lib/security/csrf/CsrfTokenManagerTest.php b/tests/lib/Security/CSRF/CsrfTokenManagerTest.php
similarity index 100%
rename from tests/lib/security/csrf/CsrfTokenManagerTest.php
rename to tests/lib/Security/CSRF/CsrfTokenManagerTest.php
diff --git a/tests/lib/security/csrf/CsrfTokenTest.php b/tests/lib/Security/CSRF/CsrfTokenTest.php
similarity index 100%
rename from tests/lib/security/csrf/CsrfTokenTest.php
rename to tests/lib/Security/CSRF/CsrfTokenTest.php
diff --git a/tests/lib/security/csrf/tokenstorage/SessionStorageTest.php b/tests/lib/Security/CSRF/TokenStorage/SessionStorageTest.php
similarity index 100%
rename from tests/lib/security/csrf/tokenstorage/SessionStorageTest.php
rename to tests/lib/Security/CSRF/TokenStorage/SessionStorageTest.php
diff --git a/tests/lib/security/CertificateManagerTest.php b/tests/lib/Security/CertificateManagerTest.php
similarity index 100%
rename from tests/lib/security/CertificateManagerTest.php
rename to tests/lib/Security/CertificateManagerTest.php
diff --git a/tests/lib/security/CertificateTest.php b/tests/lib/Security/CertificateTest.php
similarity index 100%
rename from tests/lib/security/CertificateTest.php
rename to tests/lib/Security/CertificateTest.php
diff --git a/tests/lib/security/CredentialsManagerTest.php b/tests/lib/Security/CredentialsManagerTest.php
similarity index 100%
rename from tests/lib/security/CredentialsManagerTest.php
rename to tests/lib/Security/CredentialsManagerTest.php
diff --git a/tests/lib/security/CryptoTest.php b/tests/lib/Security/CryptoTest.php
similarity index 100%
rename from tests/lib/security/CryptoTest.php
rename to tests/lib/Security/CryptoTest.php
diff --git a/tests/lib/security/HasherTest.php b/tests/lib/Security/HasherTest.php
similarity index 100%
rename from tests/lib/security/HasherTest.php
rename to tests/lib/Security/HasherTest.php
diff --git a/tests/lib/security/SecureRandomTest.php b/tests/lib/Security/SecureRandomTest.php
similarity index 100%
rename from tests/lib/security/SecureRandomTest.php
rename to tests/lib/Security/SecureRandomTest.php
diff --git a/tests/lib/security/TrustedDomainHelperTest.php b/tests/lib/Security/TrustedDomainHelperTest.php
similarity index 100%
rename from tests/lib/security/TrustedDomainHelperTest.php
rename to tests/lib/Security/TrustedDomainHelperTest.php
diff --git a/tests/lib/server.php b/tests/lib/ServerTest.php
similarity index 99%
rename from tests/lib/server.php
rename to tests/lib/ServerTest.php
index fe3c6fd5ee8f721df60d45180102629a03f1afba..534f3f8cfd59f30a0307205054c1ecf1d4fb2132 100644
--- a/tests/lib/server.php
+++ b/tests/lib/ServerTest.php
@@ -31,7 +31,7 @@ namespace Test;
  *
  * @package Test
  */
-class Server extends \Test\TestCase {
+class ServerTest extends \Test\TestCase {
 	/** @var \OC\Server */
 	protected $server;
 
diff --git a/tests/lib/session/cryptosessiondatatest.php b/tests/lib/Session/CryptoSessionDataTest.php
similarity index 100%
rename from tests/lib/session/cryptosessiondatatest.php
rename to tests/lib/Session/CryptoSessionDataTest.php
diff --git a/tests/lib/session/cryptowrappingtest.php b/tests/lib/Session/CryptoWrappingTest.php
similarity index 100%
rename from tests/lib/session/cryptowrappingtest.php
rename to tests/lib/Session/CryptoWrappingTest.php
diff --git a/tests/lib/session/memory.php b/tests/lib/Session/MemoryTest.php
similarity index 79%
rename from tests/lib/session/memory.php
rename to tests/lib/Session/MemoryTest.php
index dbf2737fb3f64f5a1c560dfa1142b16b5a70b587..d92d7b90e5e2cb7709ed670977f8a5649b8272f1 100644
--- a/tests/lib/session/memory.php
+++ b/tests/lib/Session/MemoryTest.php
@@ -9,7 +9,7 @@
 
 namespace Test\Session;
 
-class Memory extends Session {
+class MemoryTest extends Session {
 
 	protected function setUp() {
 		parent::setUp();
@@ -17,7 +17,7 @@ class Memory extends Session {
 	}
 
 	/**
-	 * @expectedException OCP\Session\Exceptions\SessionNotAvailableException
+	 * @expectedException \OCP\Session\Exceptions\SessionNotAvailableException
 	 */
 	public function testThrowsExceptionOnGetId() {
 		$this->instance->getId();
diff --git a/tests/lib/session/session.php b/tests/lib/Session/Session.php
similarity index 100%
rename from tests/lib/session/session.php
rename to tests/lib/Session/Session.php
diff --git a/tests/lib/share/backend.php b/tests/lib/Share/Backend.php
similarity index 100%
rename from tests/lib/share/backend.php
rename to tests/lib/Share/Backend.php
diff --git a/tests/lib/share/helper.php b/tests/lib/Share/HelperTest.php
similarity index 99%
rename from tests/lib/share/helper.php
rename to tests/lib/Share/HelperTest.php
index 3fe6389c4082d22121236a3af7a3201bc1f3b03f..02118bf0e2e73b398e8ebdde57404ead93d32cad 100644
--- a/tests/lib/share/helper.php
+++ b/tests/lib/Share/HelperTest.php
@@ -25,7 +25,7 @@ namespace Test\Share;
  * @group DB
  * Class Helper
  */
-class Helper extends \Test\TestCase {
+class HelperTest extends \Test\TestCase {
 
 	public function expireDateProvider() {
 		return array(
diff --git a/tests/lib/share/MailNotificationsTest.php b/tests/lib/Share/MailNotificationsTest.php
similarity index 100%
rename from tests/lib/share/MailNotificationsTest.php
rename to tests/lib/Share/MailNotificationsTest.php
diff --git a/tests/lib/share/searchresultsorter.php b/tests/lib/Share/SearchResultSorterTest.php
similarity index 96%
rename from tests/lib/share/searchresultsorter.php
rename to tests/lib/Share/SearchResultSorterTest.php
index 6bee5dfe7f0c228606ef35c7d002a45a099983c1..7feccdd82f5693e363eec4e7ec08d107b6bb4210 100644
--- a/tests/lib/share/searchresultsorter.php
+++ b/tests/lib/Share/SearchResultSorterTest.php
@@ -21,7 +21,7 @@
 
 namespace Test\Share;
 
-class SearchResultSorter extends \Test\TestCase {
+class SearchResultSorterTest extends \Test\TestCase {
 	public function testSort() {
 		$search = 'lin';
 		$sorter = new \OC\Share\SearchResultSorter($search, 'foobar');
diff --git a/tests/lib/share/share.php b/tests/lib/Share/ShareTest.php
similarity index 99%
rename from tests/lib/share/share.php
rename to tests/lib/Share/ShareTest.php
index 355005bb58648ed6c2d148c8d00185979dc2ba4c..339193e7ff23c74bf8e39f2d5fe0945b3fbb2289 100644
--- a/tests/lib/share/share.php
+++ b/tests/lib/Share/ShareTest.php
@@ -26,7 +26,7 @@ namespace Test\Share;
  *
  * @group DB
  */
-class Share extends \Test\TestCase {
+class ShareTest extends \Test\TestCase {
 
 	protected $itemType;
 	protected $userBackend;
diff --git a/tests/lib/share20/defaultshareprovidertest.php b/tests/lib/Share20/DefaultShareProviderTest.php
similarity index 100%
rename from tests/lib/share20/defaultshareprovidertest.php
rename to tests/lib/Share20/DefaultShareProviderTest.php
diff --git a/tests/lib/share20/managertest.php b/tests/lib/Share20/ManagerTest.php
similarity index 100%
rename from tests/lib/share20/managertest.php
rename to tests/lib/Share20/ManagerTest.php
diff --git a/tests/lib/share20/sharetest.php b/tests/lib/Share20/ShareTest.php
similarity index 100%
rename from tests/lib/share20/sharetest.php
rename to tests/lib/Share20/ShareTest.php
diff --git a/tests/lib/subadmin.php b/tests/lib/SubAdminTest.php
similarity index 99%
rename from tests/lib/subadmin.php
rename to tests/lib/SubAdminTest.php
index 960943c22f5cf55dd60b7065a1922ac15b94ce84..c1159132a50f8728682db0362516f111f7f0873b 100644
--- a/tests/lib/subadmin.php
+++ b/tests/lib/SubAdminTest.php
@@ -20,7 +20,7 @@
  */
 namespace Test;
 
-class SubAdmin extends \Test\TestCase {
+class SubAdminTest extends \Test\TestCase {
 
 	/** @var \OCP\IUserManager */
 	private $userManager;
diff --git a/tests/lib/systemtag/systemtagmanagertest.php b/tests/lib/SystemTag/SystemTagManagerTest.php
similarity index 100%
rename from tests/lib/systemtag/systemtagmanagertest.php
rename to tests/lib/SystemTag/SystemTagManagerTest.php
diff --git a/tests/lib/systemtag/systemtagobjectmappertest.php b/tests/lib/SystemTag/SystemTagObjectMapperTest.php
similarity index 100%
rename from tests/lib/systemtag/systemtagobjectmappertest.php
rename to tests/lib/SystemTag/SystemTagObjectMapperTest.php
diff --git a/tests/lib/tempmanager.php b/tests/lib/TempManagerTest.php
similarity index 99%
rename from tests/lib/tempmanager.php
rename to tests/lib/TempManagerTest.php
index 8faf804a2031cad6544c75204b8c3fdaee8fa1b2..0eaca464c74c0afb91565ebdd2e26cebc84d154c 100644
--- a/tests/lib/tempmanager.php
+++ b/tests/lib/TempManagerTest.php
@@ -21,7 +21,7 @@ class NullLogger extends Log {
 	}
 }
 
-class TempManager extends \Test\TestCase {
+class TempManagerTest extends \Test\TestCase {
 
 	protected $baseDir = null;
 
diff --git a/tests/lib/template/resourcelocator.php b/tests/lib/Template/ResourceLocatorTest.php
similarity index 98%
rename from tests/lib/template/resourcelocator.php
rename to tests/lib/Template/ResourceLocatorTest.php
index ef5e2ed13575b861486f11803f5094e6785d78a6..1918b927c94de9535eb926ede3d7221dcafa0f6c 100644
--- a/tests/lib/template/resourcelocator.php
+++ b/tests/lib/Template/ResourceLocatorTest.php
@@ -10,7 +10,7 @@ namespace Test\Template;
 
 use OC\Template\ResourceNotFoundException;
 
-class ResourceLocator extends \Test\TestCase {
+class ResourceLocatorTest extends \Test\TestCase {
 	/** @var \PHPUnit_Framework_MockObject_MockObject */
 	protected $logger;
 
diff --git a/tests/lib/testmoveablemountpoint.php b/tests/lib/TestMoveableMountPoint.php
similarity index 100%
rename from tests/lib/testmoveablemountpoint.php
rename to tests/lib/TestMoveableMountPoint.php
diff --git a/tests/lib/traits/encryptiontrait.php b/tests/lib/Traits/EncryptionTrait.php
similarity index 100%
rename from tests/lib/traits/encryptiontrait.php
rename to tests/lib/Traits/EncryptionTrait.php
diff --git a/tests/lib/traits/mountprovidertrait.php b/tests/lib/Traits/MountProviderTrait.php
similarity index 100%
rename from tests/lib/traits/mountprovidertrait.php
rename to tests/lib/Traits/MountProviderTrait.php
diff --git a/tests/lib/traits/usertrait.php b/tests/lib/Traits/UserTrait.php
similarity index 100%
rename from tests/lib/traits/usertrait.php
rename to tests/lib/Traits/UserTrait.php
diff --git a/tests/lib/updater/VersionCheckTest.php b/tests/lib/Updater/VersionCheckTest.php
similarity index 99%
rename from tests/lib/updater/VersionCheckTest.php
rename to tests/lib/Updater/VersionCheckTest.php
index 13851338eeff9162e5185d9332e59b700b65b172..fb43571ceceb3a722180519985cba871c9f3c4f2 100644
--- a/tests/lib/updater/VersionCheckTest.php
+++ b/tests/lib/Updater/VersionCheckTest.php
@@ -20,7 +20,7 @@
  *
  */
 
-namespace Test\Update;
+namespace Test\Updater;
 
 use OC\Updater\VersionCheck;
 use OCP\IConfig;
diff --git a/tests/lib/user/avataruserdummy.php b/tests/lib/User/AvatarUserDummy.php
similarity index 100%
rename from tests/lib/user/avataruserdummy.php
rename to tests/lib/User/AvatarUserDummy.php
diff --git a/tests/lib/user/backend.php b/tests/lib/User/Backend.php
similarity index 100%
rename from tests/lib/user/backend.php
rename to tests/lib/User/Backend.php
diff --git a/tests/lib/user/database.php b/tests/lib/User/DatabaseTest.php
similarity index 95%
rename from tests/lib/user/database.php
rename to tests/lib/User/DatabaseTest.php
index 76d6226a7fd03708fca78954d15d5348c7f99dcd..270d90b35bc83d8f3e2bb8dc4a091dcda5e16737 100644
--- a/tests/lib/user/database.php
+++ b/tests/lib/User/DatabaseTest.php
@@ -23,11 +23,11 @@
 namespace Test\User;
 
 /**
- * Class Test_User_Database
+ * Class DatabaseTest
  *
  * @group DB
  */
-class Database extends Backend {
+class DatabaseTest extends Backend {
 	/** @var array */
 	private $users;
 
diff --git a/tests/lib/user/dummy.php b/tests/lib/User/Dummy.php
similarity index 100%
rename from tests/lib/user/dummy.php
rename to tests/lib/User/Dummy.php
diff --git a/tests/lib/user/manager.php b/tests/lib/User/ManagerTest.php
similarity index 99%
rename from tests/lib/user/manager.php
rename to tests/lib/User/ManagerTest.php
index 14221e4a6654901fa2e35d620069e4c91a2a03e5..2a6cdbc1355f874b76ab913c2d9c53f811b8f6f2 100644
--- a/tests/lib/user/manager.php
+++ b/tests/lib/User/ManagerTest.php
@@ -10,13 +10,13 @@
 namespace Test\User;
 
 /**
- * Class Manager
+ * Class ManagerTest
  *
  * @group DB
  *
  * @package Test\User
  */
-class Manager extends \Test\TestCase {
+class ManagerTest extends \Test\TestCase {
 	public function testGetBackends() {
 		$userDummyBackend = $this->getMock('\Test\Util\User\Dummy');
 		$manager = new \OC\User\Manager();
diff --git a/tests/lib/user/session.php b/tests/lib/User/SessionTest.php
similarity index 99%
rename from tests/lib/user/session.php
rename to tests/lib/User/SessionTest.php
index 444735b854f0ba63a76dc9c2f98f785921e1f8fa..4438487e2a0b458d94e3e172cdbd0b806385fd38 100644
--- a/tests/lib/user/session.php
+++ b/tests/lib/User/SessionTest.php
@@ -16,7 +16,7 @@ use OC\User\User;
  * @group DB
  * @package Test\User
  */
-class Session extends \Test\TestCase {
+class SessionTest extends \Test\TestCase {
 
 	/** @var \OCP\AppFramework\Utility\ITimeFactory */
 	private $timeFactory;
diff --git a/tests/lib/user/user.php b/tests/lib/User/UserTest.php
similarity index 98%
rename from tests/lib/user/user.php
rename to tests/lib/User/UserTest.php
index 71be3691003c3116b54fd83bda755f9397a852c8..a49bddde9eb703cb77a0df6a57e4ceda91944dfa 100644
--- a/tests/lib/user/user.php
+++ b/tests/lib/User/UserTest.php
@@ -12,13 +12,13 @@ namespace Test\User;
 use OC\Hooks\PublicEmitter;
 
 /**
- * Class User
+ * Class UserTest
  *
  * @group DB
  *
  * @package Test\User
  */
-class User extends \Test\TestCase {
+class UserTest extends \Test\TestCase {
 	public function testDisplayName() {
 		/**
 		 * @var \OC\User\Backend | \PHPUnit_Framework_MockObject_MockObject $backend
@@ -120,7 +120,6 @@ class User extends \Test\TestCase {
 		/**
 		 * @var \OC\User\Backend | \PHPUnit_Framework_MockObject_MockObject $backend
 		 */
-		require_once 'avataruserdummy.php';
 		$backend = $this->getMock('Test\User\AvatarUserDummy');
 		$backend->expects($this->once())
 			->method('canChangeAvatar')
@@ -145,7 +144,6 @@ class User extends \Test\TestCase {
 		/**
 		 * @var \OC\User\Backend | \PHPUnit_Framework_MockObject_MockObject $backend
 		 */
-		require_once 'avataruserdummy.php';
 		$backend = $this->getMock('Test\User\AvatarUserDummy');
 		$backend->expects($this->once())
 			->method('canChangeAvatar')
@@ -170,7 +168,6 @@ class User extends \Test\TestCase {
 		/**
 		 * @var \OC\User\Backend | \PHPUnit_Framework_MockObject_MockObject $backend
 		 */
-		require_once 'avataruserdummy.php';
 		$backend = $this->getMock('Test\User\AvatarUserDummy');
 		$backend->expects($this->never())
 			->method('canChangeAvatar');
diff --git a/tests/lib/user.php b/tests/lib/UserTest.php
similarity index 97%
rename from tests/lib/user.php
rename to tests/lib/UserTest.php
index dc5551d1cad96036beee7fcadea53a9a4612ed63..456e864ab75a6bacb9af2377ef76f29b30c364c1 100644
--- a/tests/lib/user.php
+++ b/tests/lib/UserTest.php
@@ -16,7 +16,7 @@ namespace Test;
  *
  * @package Test
  */
-class User extends TestCase {
+class UserTest extends TestCase {
 	/**
 	 * @var \OC\User\Backend | \PHPUnit_Framework_MockObject_MockObject $backend
 	 */
diff --git a/tests/lib/util/group/dummy.php b/tests/lib/Util/Group/Dummy.php
similarity index 100%
rename from tests/lib/util/group/dummy.php
rename to tests/lib/Util/Group/Dummy.php
diff --git a/tests/lib/util/user/dummy.php b/tests/lib/Util/User/Dummy.php
similarity index 100%
rename from tests/lib/util/user/dummy.php
rename to tests/lib/Util/User/Dummy.php