addPsr4('Tests\\', OC::$SERVERROOT . '/tests/', true); $dontLoadApps = getenv('TEST_DONT_LOAD_APPS'); if (!$dontLoadApps) { // load all apps $appManager = Server::get(IAppManager::class); foreach (new \DirectoryIterator(__DIR__ . '/../apps/') as $file) { if ($file->isDot()) { continue; } $appManager->loadApp($file->getFilename()); } } // Recorded on CI by default; set TEST_LOG_HTTP to a path for a manual run. $logHttp = getenv('TEST_LOG_HTTP') ?: (getenv('CI') ? OC::$SERVERROOT . '/http-requests.log' : ''); if ($logHttp !== '') { \Test\HttpRequestLogger::install($logHttp); } OC_Hook::clear(); set_include_path( get_include_path() . PATH_SEPARATOR . '/usr/share/php' . PATH_SEPARATOR . __DIR__ . '/..' );