diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/l10n/es.js | 2 | ||||
-rw-r--r-- | lib/l10n/es.json | 2 | ||||
-rw-r--r-- | lib/l10n/fr.js | 1 | ||||
-rw-r--r-- | lib/l10n/fr.json | 1 | ||||
-rw-r--r-- | lib/l10n/it.js | 2 | ||||
-rw-r--r-- | lib/l10n/it.json | 2 | ||||
-rw-r--r-- | lib/l10n/nl.js | 15 | ||||
-rw-r--r-- | lib/l10n/nl.json | 15 | ||||
-rw-r--r-- | lib/l10n/pt_BR.js | 1 | ||||
-rw-r--r-- | lib/l10n/pt_BR.json | 1 | ||||
-rw-r--r-- | lib/private/AppFramework/Middleware/OCSMiddleware.php | 7 | ||||
-rw-r--r-- | lib/private/Authentication/TwoFactorAuth/Manager.php | 20 | ||||
-rw-r--r-- | lib/private/Log.php | 7 | ||||
-rw-r--r-- | lib/private/Log/File.php (renamed from lib/private/Log/Owncloud.php) | 2 | ||||
-rw-r--r-- | lib/private/Server.php | 14 | ||||
-rw-r--r-- | lib/private/URLGenerator.php | 3 | ||||
-rw-r--r-- | lib/private/legacy/app.php | 2 |
17 files changed, 66 insertions, 31 deletions
diff --git a/lib/l10n/es.js b/lib/l10n/es.js index 5a630b1a1fc..00a47468903 100644 --- a/lib/l10n/es.js +++ b/lib/l10n/es.js @@ -115,6 +115,7 @@ OC.L10N.register( "The username is already being used" : "El nombre de usuario ya está en uso", "Login canceled by app" : "Login cancelado por la app", "User disabled" : "Usuario deshabilitado", + "Help" : "Ayuda", "Personal" : "Personal", "Users" : "Usuarios", "Admin" : "Administración", @@ -123,6 +124,7 @@ OC.L10N.register( "App \"%s\" cannot be installed because it is not compatible with this version of the server." : "La aplicación \"%s\" no se puede instalar porque no es compatible con esta versión del servidor.", "App \"%s\" cannot be installed because the following dependencies are not fulfilled: %s" : "La app \"%s\" no puede instalarse porque las siguientes dependencias no están cumplimentadas: %s", "No app name specified" : "No se ha especificado nombre de la aplicación", + "App '%s' could not be installed!" : "¡No se pudo instalar la app '%s'!", "a safe home for all your data" : "un hogar seguro para todos tus datos", "File is currently busy, please try again later" : "Archivo se encuentra actualmente ocupado, por favor inténtelo de nuevo más tarde", "Can't read file" : "No se puede leer archivo", diff --git a/lib/l10n/es.json b/lib/l10n/es.json index 1ee4027ccb0..fc0f223ef37 100644 --- a/lib/l10n/es.json +++ b/lib/l10n/es.json @@ -113,6 +113,7 @@ "The username is already being used" : "El nombre de usuario ya está en uso", "Login canceled by app" : "Login cancelado por la app", "User disabled" : "Usuario deshabilitado", + "Help" : "Ayuda", "Personal" : "Personal", "Users" : "Usuarios", "Admin" : "Administración", @@ -121,6 +122,7 @@ "App \"%s\" cannot be installed because it is not compatible with this version of the server." : "La aplicación \"%s\" no se puede instalar porque no es compatible con esta versión del servidor.", "App \"%s\" cannot be installed because the following dependencies are not fulfilled: %s" : "La app \"%s\" no puede instalarse porque las siguientes dependencias no están cumplimentadas: %s", "No app name specified" : "No se ha especificado nombre de la aplicación", + "App '%s' could not be installed!" : "¡No se pudo instalar la app '%s'!", "a safe home for all your data" : "un hogar seguro para todos tus datos", "File is currently busy, please try again later" : "Archivo se encuentra actualmente ocupado, por favor inténtelo de nuevo más tarde", "Can't read file" : "No se puede leer archivo", diff --git a/lib/l10n/fr.js b/lib/l10n/fr.js index c66d65709e9..61107d4df83 100644 --- a/lib/l10n/fr.js +++ b/lib/l10n/fr.js @@ -115,6 +115,7 @@ OC.L10N.register( "The username is already being used" : "Ce nom d'utilisateur est déjà utilisé", "Login canceled by app" : "L'authentification a été annulé par l'application", "User disabled" : "Utilisateur désactivé", + "Help" : "Aide", "Personal" : "Personnel", "Users" : "Utilisateurs", "Admin" : "Administration", diff --git a/lib/l10n/fr.json b/lib/l10n/fr.json index 6e3d2c70a2f..197862d6561 100644 --- a/lib/l10n/fr.json +++ b/lib/l10n/fr.json @@ -113,6 +113,7 @@ "The username is already being used" : "Ce nom d'utilisateur est déjà utilisé", "Login canceled by app" : "L'authentification a été annulé par l'application", "User disabled" : "Utilisateur désactivé", + "Help" : "Aide", "Personal" : "Personnel", "Users" : "Utilisateurs", "Admin" : "Administration", diff --git a/lib/l10n/it.js b/lib/l10n/it.js index bf042a58286..9be3da55090 100644 --- a/lib/l10n/it.js +++ b/lib/l10n/it.js @@ -115,6 +115,7 @@ OC.L10N.register( "The username is already being used" : "Il nome utente è già utilizzato", "Login canceled by app" : "Accesso annullato dall'applicazione", "User disabled" : "Utente disabilitato", + "Help" : "Aiuto", "Personal" : "Personale", "Users" : "Utenti", "Admin" : "Admin", @@ -123,6 +124,7 @@ OC.L10N.register( "App \"%s\" cannot be installed because it is not compatible with this version of the server." : "L'applicazione \"%s\" non può essere installata perché non è compatibile con questa versione del server.", "App \"%s\" cannot be installed because the following dependencies are not fulfilled: %s" : "L'applicazione \"%s\" non può essere installata poiché le seguenti dipendenze non sono soddisfatte: %s", "No app name specified" : "Il nome dell'applicazione non è specificato", + "App '%s' could not be installed!" : "L'applicazione '%s' non può essere installata!", "a safe home for all your data" : "un posto sicuro per tutti i tuoi dati", "File is currently busy, please try again later" : "Il file è attualmente occupato, riprova più tardi", "Can't read file" : "Impossibile leggere il file", diff --git a/lib/l10n/it.json b/lib/l10n/it.json index 5e04cc1003e..20bc25cb21d 100644 --- a/lib/l10n/it.json +++ b/lib/l10n/it.json @@ -113,6 +113,7 @@ "The username is already being used" : "Il nome utente è già utilizzato", "Login canceled by app" : "Accesso annullato dall'applicazione", "User disabled" : "Utente disabilitato", + "Help" : "Aiuto", "Personal" : "Personale", "Users" : "Utenti", "Admin" : "Admin", @@ -121,6 +122,7 @@ "App \"%s\" cannot be installed because it is not compatible with this version of the server." : "L'applicazione \"%s\" non può essere installata perché non è compatibile con questa versione del server.", "App \"%s\" cannot be installed because the following dependencies are not fulfilled: %s" : "L'applicazione \"%s\" non può essere installata poiché le seguenti dipendenze non sono soddisfatte: %s", "No app name specified" : "Il nome dell'applicazione non è specificato", + "App '%s' could not be installed!" : "L'applicazione '%s' non può essere installata!", "a safe home for all your data" : "un posto sicuro per tutti i tuoi dati", "File is currently busy, please try again later" : "Il file è attualmente occupato, riprova più tardi", "Can't read file" : "Impossibile leggere il file", diff --git a/lib/l10n/nl.js b/lib/l10n/nl.js index c35b5554267..623a6e58af6 100644 --- a/lib/l10n/nl.js +++ b/lib/l10n/nl.js @@ -35,7 +35,7 @@ OC.L10N.register( "Dot files are not allowed" : "Punt bestanden zijn niet toegestaan", "4-byte characters are not supported in file names" : "4-byte tekens in bestandsnamen worden niet ondersteund", "File name is a reserved word" : "Bestandsnaam is een gereserveerd woord", - "File name contains at least one invalid character" : "De bestandsnaam bevat ten minste één verboden teken", + "File name contains at least one invalid character" : "De bestandsnaam bevat in ieder geval één verboden teken", "File name is too long" : "De bestandsnaam is te lang", "App directory already exists" : "App directory bestaat al", "Can't create app folder. Please fix permissions. %s" : "Kan de app map niet aanmaken, Herstel de permissies. %s", @@ -71,11 +71,11 @@ OC.L10N.register( "Set an admin password." : "Stel een beheerderswachtwoord in.", "Can't create or write into the data directory %s" : "Kan niets creëren of wegschrijven in datadirectory %s", "Invalid Federated Cloud ID" : "Ongeldige Federated Cloud ID", - "%s shared »%s« with you" : "%s deelde »%s« met u", + "%s shared »%s« with you" : "%s deelde »%s« met jou", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Delen van %s is mislukt, omdat de share-backend niet toestaat om type %i te delen", "Sharing %s failed, because the file does not exist" : "Delen van %s is mislukt, omdat het bestand niet bestaat", - "You are not allowed to share %s" : "U bent niet bevoegd om %s te delen", + "You are not allowed to share %s" : "Je bent niet bevoegd om %s te delen", "Sharing %s failed, because you can not share with yourself" : "Delen van %s is mislukt, omdat je niet met jezelf kan delen", "Sharing %s failed, because the user %s does not exist" : "Delen van %s is mislukt, omdat gebruiker %s niet bestaat", "Sharing %s failed, because the user %s is not a member of any groups that %s is a member of" : "Delen van %s is mislukt, omdat gebruiker %s geen lid is van een groep waar %s lid van is", @@ -115,6 +115,7 @@ OC.L10N.register( "The username is already being used" : "De gebruikersnaam bestaat al", "Login canceled by app" : "Inloggen geannuleerd door app", "User disabled" : "Gebruiker gedeactiveerd", + "Help" : "Help", "Personal" : "Persoonlijk", "Users" : "Gebruikers", "Admin" : "Beheerder", @@ -149,17 +150,17 @@ OC.L10N.register( "mbstring.func_overload is set to \"%s\" instead of the expected value \"0\"" : "mbstring.func_overload is ingesteld op \"%s\" in plaats van op de verwachte waarde \"0\"", "To fix this issue set <code>mbstring.func_overload</code> to <code>0</code> in your php.ini" : "Om dit op te lossen stel <code>mbstring.func_overload</code> in op <code>0</code> in uw php.ini", "libxml2 2.7.0 is at least required. Currently %s is installed." : "De laagste toegestane libxml2 versie is 2.7.0. Momenteel is %s is geïnstalleerd.", - "To fix this issue update your libxml2 version and restart your web server." : "Om dit te herstellen, moet u de libxml2 versie bijwerken en uw webserver herstarten.", + "To fix this issue update your libxml2 version and restart your web server." : "Om dit te herstellen, moet je de libxml2 versie bijwerken en je webserver herstarten.", "PHP is apparently set up to strip inline doc blocks. This will make several core apps inaccessible." : "PHP is blijkbaar zo ingesteld dat inline doc blokken worden gestript. Hierdoor worden verschillende kernmodules onbruikbaar.", "This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "Dit wordt vermoedelijk veroorzaakt door een cache/accelerator, zoals Zend OPcache of eAccelerator.", "PHP modules have been installed, but they are still listed as missing?" : "PHP modules zijn geïnstalleerd, maar worden ze nog steeds als ontbrekend aangegeven?", - "Please ask your server administrator to restart the web server." : "Vraag uw beheerder de webserver opnieuw op te starten.", + "Please ask your server administrator to restart the web server." : "Vraag je beheerder de webserver opnieuw op te starten.", "PostgreSQL >= 9 required" : "PostgreSQL >= 9 vereist", - "Please upgrade your database version" : "Werk uw database versie bij", + "Please upgrade your database version" : "Werk je databaseversie bij", "Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Wijzig de permissies in 0770 zodat de directory niet door anderen bekeken kan worden.", "Data directory (%s) is readable by other users" : "De datadirectory (%s) is leesbaar voor andere gebruikers", "Data directory (%s) must be an absolute path" : "De datadirectory (%s) moet een absoluut pad hebben", - "Check the value of \"datadirectory\" in your configuration" : "Controleer de waarde van \"datadirectory\" in uw configuratie", + "Check the value of \"datadirectory\" in your configuration" : "Controleer de waarde van \"datadirectory\" in je configuratie", "Data directory (%s) is invalid" : "Data directory (%s) is ongeldig", "Please check that the data directory contains a file \".ocdata\" in its root." : "Verifieer dat de data directory een bestand \".ocdata\" in de hoofdmap heeft.", "Could not obtain lock type %d on \"%s\"." : "Kon geen lock type %d krijgen op \"%s\".", diff --git a/lib/l10n/nl.json b/lib/l10n/nl.json index f5906e1e75e..854613ef33f 100644 --- a/lib/l10n/nl.json +++ b/lib/l10n/nl.json @@ -33,7 +33,7 @@ "Dot files are not allowed" : "Punt bestanden zijn niet toegestaan", "4-byte characters are not supported in file names" : "4-byte tekens in bestandsnamen worden niet ondersteund", "File name is a reserved word" : "Bestandsnaam is een gereserveerd woord", - "File name contains at least one invalid character" : "De bestandsnaam bevat ten minste één verboden teken", + "File name contains at least one invalid character" : "De bestandsnaam bevat in ieder geval één verboden teken", "File name is too long" : "De bestandsnaam is te lang", "App directory already exists" : "App directory bestaat al", "Can't create app folder. Please fix permissions. %s" : "Kan de app map niet aanmaken, Herstel de permissies. %s", @@ -69,11 +69,11 @@ "Set an admin password." : "Stel een beheerderswachtwoord in.", "Can't create or write into the data directory %s" : "Kan niets creëren of wegschrijven in datadirectory %s", "Invalid Federated Cloud ID" : "Ongeldige Federated Cloud ID", - "%s shared »%s« with you" : "%s deelde »%s« met u", + "%s shared »%s« with you" : "%s deelde »%s« met jou", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Delen van %s is mislukt, omdat de share-backend niet toestaat om type %i te delen", "Sharing %s failed, because the file does not exist" : "Delen van %s is mislukt, omdat het bestand niet bestaat", - "You are not allowed to share %s" : "U bent niet bevoegd om %s te delen", + "You are not allowed to share %s" : "Je bent niet bevoegd om %s te delen", "Sharing %s failed, because you can not share with yourself" : "Delen van %s is mislukt, omdat je niet met jezelf kan delen", "Sharing %s failed, because the user %s does not exist" : "Delen van %s is mislukt, omdat gebruiker %s niet bestaat", "Sharing %s failed, because the user %s is not a member of any groups that %s is a member of" : "Delen van %s is mislukt, omdat gebruiker %s geen lid is van een groep waar %s lid van is", @@ -113,6 +113,7 @@ "The username is already being used" : "De gebruikersnaam bestaat al", "Login canceled by app" : "Inloggen geannuleerd door app", "User disabled" : "Gebruiker gedeactiveerd", + "Help" : "Help", "Personal" : "Persoonlijk", "Users" : "Gebruikers", "Admin" : "Beheerder", @@ -147,17 +148,17 @@ "mbstring.func_overload is set to \"%s\" instead of the expected value \"0\"" : "mbstring.func_overload is ingesteld op \"%s\" in plaats van op de verwachte waarde \"0\"", "To fix this issue set <code>mbstring.func_overload</code> to <code>0</code> in your php.ini" : "Om dit op te lossen stel <code>mbstring.func_overload</code> in op <code>0</code> in uw php.ini", "libxml2 2.7.0 is at least required. Currently %s is installed." : "De laagste toegestane libxml2 versie is 2.7.0. Momenteel is %s is geïnstalleerd.", - "To fix this issue update your libxml2 version and restart your web server." : "Om dit te herstellen, moet u de libxml2 versie bijwerken en uw webserver herstarten.", + "To fix this issue update your libxml2 version and restart your web server." : "Om dit te herstellen, moet je de libxml2 versie bijwerken en je webserver herstarten.", "PHP is apparently set up to strip inline doc blocks. This will make several core apps inaccessible." : "PHP is blijkbaar zo ingesteld dat inline doc blokken worden gestript. Hierdoor worden verschillende kernmodules onbruikbaar.", "This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "Dit wordt vermoedelijk veroorzaakt door een cache/accelerator, zoals Zend OPcache of eAccelerator.", "PHP modules have been installed, but they are still listed as missing?" : "PHP modules zijn geïnstalleerd, maar worden ze nog steeds als ontbrekend aangegeven?", - "Please ask your server administrator to restart the web server." : "Vraag uw beheerder de webserver opnieuw op te starten.", + "Please ask your server administrator to restart the web server." : "Vraag je beheerder de webserver opnieuw op te starten.", "PostgreSQL >= 9 required" : "PostgreSQL >= 9 vereist", - "Please upgrade your database version" : "Werk uw database versie bij", + "Please upgrade your database version" : "Werk je databaseversie bij", "Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Wijzig de permissies in 0770 zodat de directory niet door anderen bekeken kan worden.", "Data directory (%s) is readable by other users" : "De datadirectory (%s) is leesbaar voor andere gebruikers", "Data directory (%s) must be an absolute path" : "De datadirectory (%s) moet een absoluut pad hebben", - "Check the value of \"datadirectory\" in your configuration" : "Controleer de waarde van \"datadirectory\" in uw configuratie", + "Check the value of \"datadirectory\" in your configuration" : "Controleer de waarde van \"datadirectory\" in je configuratie", "Data directory (%s) is invalid" : "Data directory (%s) is ongeldig", "Please check that the data directory contains a file \".ocdata\" in its root." : "Verifieer dat de data directory een bestand \".ocdata\" in de hoofdmap heeft.", "Could not obtain lock type %d on \"%s\"." : "Kon geen lock type %d krijgen op \"%s\".", diff --git a/lib/l10n/pt_BR.js b/lib/l10n/pt_BR.js index 439ca4360c5..2321fb82da2 100644 --- a/lib/l10n/pt_BR.js +++ b/lib/l10n/pt_BR.js @@ -115,6 +115,7 @@ OC.L10N.register( "The username is already being used" : "Este nome de usuário já está sendo usado", "Login canceled by app" : "Login cancelado pelo aplicativo", "User disabled" : "Usuário desativado", + "Help" : "Ajuda", "Personal" : "Pessoal", "Users" : "Usuários", "Admin" : "Admin", diff --git a/lib/l10n/pt_BR.json b/lib/l10n/pt_BR.json index 3806bdb4c3f..980756257ff 100644 --- a/lib/l10n/pt_BR.json +++ b/lib/l10n/pt_BR.json @@ -113,6 +113,7 @@ "The username is already being used" : "Este nome de usuário já está sendo usado", "Login canceled by app" : "Login cancelado pelo aplicativo", "User disabled" : "Usuário desativado", + "Help" : "Ajuda", "Personal" : "Pessoal", "Users" : "Usuários", "Admin" : "Admin", diff --git a/lib/private/AppFramework/Middleware/OCSMiddleware.php b/lib/private/AppFramework/Middleware/OCSMiddleware.php index 90355a39ef0..0d97aa6ed94 100644 --- a/lib/private/AppFramework/Middleware/OCSMiddleware.php +++ b/lib/private/AppFramework/Middleware/OCSMiddleware.php @@ -56,7 +56,12 @@ class OCSMiddleware extends Middleware { if ($code === 0) { $code = Http::STATUS_INTERNAL_SERVER_ERROR; } - return new OCSResponse($format, $code, $exception->getMessage()); + $response = new OCSResponse($format, $code, $exception->getMessage()); + + if ($this->request->getScriptName() === '/ocs/v2.php') { + $response->setStatus($code); + } + return $response; } throw $exception; diff --git a/lib/private/Authentication/TwoFactorAuth/Manager.php b/lib/private/Authentication/TwoFactorAuth/Manager.php index bca75263a71..66bcafbce71 100644 --- a/lib/private/Authentication/TwoFactorAuth/Manager.php +++ b/lib/private/Authentication/TwoFactorAuth/Manager.php @@ -109,15 +109,17 @@ class Manager { foreach ($allApps as $appId) { $info = $this->appManager->getAppInfo($appId); - $providerClasses = $info['two-factor-providers']; - foreach ($providerClasses as $class) { - try { - $this->loadTwoFactorApp($appId); - $provider = OC::$server->query($class); - $providers[$provider->getId()] = $provider; - } catch (QueryException $exc) { - // Provider class can not be resolved - throw new Exception("Could not load two-factor auth provider $class"); + if (isset($info['two-factor-providers'])) { + $providerClasses = $info['two-factor-providers']; + foreach ($providerClasses as $class) { + try { + $this->loadTwoFactorApp($appId); + $provider = OC::$server->query($class); + $providers[$provider->getId()] = $provider; + } catch (QueryException $exc) { + // Provider class can not be resolved + throw new Exception("Could not load two-factor auth provider $class"); + } } } } diff --git a/lib/private/Log.php b/lib/private/Log.php index 59233cf5c12..0a707f3d4ea 100644 --- a/lib/private/Log.php +++ b/lib/private/Log.php @@ -103,7 +103,12 @@ class Log implements ILogger { // FIXME: Add this for backwards compatibility, should be fixed at some point probably if($logger === null) { - $this->logger = 'OC\\Log\\'.ucfirst($this->config->getValue('log_type', 'owncloud')); + // TODO: Drop backwards compatibility for config in the future + $logType = $this->config->getValue('log_type', 'file'); + if($logType==='owncloud') { + $logType = 'file'; + } + $this->logger = 'OC\\Log\\'.ucfirst($logType); call_user_func(array($this->logger, 'init')); } else { $this->logger = $logger; diff --git a/lib/private/Log/Owncloud.php b/lib/private/Log/File.php index 2cc70015e3c..a406dd83952 100644 --- a/lib/private/Log/Owncloud.php +++ b/lib/private/Log/File.php @@ -39,7 +39,7 @@ namespace OC\Log; * Log is saved at data/nextcloud.log (on default) */ -class Owncloud { +class File { static protected $logFile; /** diff --git a/lib/private/Server.php b/lib/private/Server.php index de2970d9bfa..41092ceae6e 100644 --- a/lib/private/Server.php +++ b/lib/private/Server.php @@ -364,8 +364,9 @@ class Server extends ServerContainer implements IServerContainer { ); }); $this->registerService('Logger', function (Server $c) { - $logClass = $c->query('AllConfig')->getSystemValue('log_type', 'owncloud'); - $logger = 'OC\\Log\\' . ucfirst($logClass); + $logClass = $c->query('AllConfig')->getSystemValue('log_type', 'file'); + // TODO: Drop backwards compatibility for config in the future + $logger = 'OC\\Log\\' . ucfirst($logClass=='owncloud' ? 'file' : $logClass); call_user_func(array($logger, 'init')); return new Log($logger); @@ -631,7 +632,14 @@ class Server extends ServerContainer implements IServerContainer { return $factory->getManager(); }); $this->registerService('ThemingDefaults', function(Server $c) { - if(class_exists('OCA\Theming\Template', false) && $this->getConfig()->getSystemValue('installed', false) && $this->getAppManager()->isInstalled('theming')) { + try { + $classExists = class_exists('OCA\Theming\Template'); + } catch (\OCP\AutoloadNotAllowedException $e) { + // App disabled or in maintenance mode + $classExists = false; + } + + if ($classExists && $this->getConfig()->getSystemValue('installed', false) && $this->getAppManager()->isInstalled('theming')) { return new Template( $this->getConfig(), $this->getL10N('theming'), diff --git a/lib/private/URLGenerator.php b/lib/private/URLGenerator.php index 0f3c60b1323..93517dc9f7e 100644 --- a/lib/private/URLGenerator.php +++ b/lib/private/URLGenerator.php @@ -30,7 +30,8 @@ */ namespace OC; -use OCP\Defaults; + + use OCP\ICacheFactory; use OCP\IConfig; use OCP\IURLGenerator; diff --git a/lib/private/legacy/app.php b/lib/private/legacy/app.php index 4cfa68cff2d..5395d1daeee 100644 --- a/lib/private/legacy/app.php +++ b/lib/private/legacy/app.php @@ -169,7 +169,7 @@ class OC_App { // Register on PSR-4 composer autoloader $appNamespace = \OC\AppFramework\App::buildAppNamespace($app); \OC::$composerAutoloader->addPsr4($appNamespace . '\\', $path . '/lib/', true); - if (defined('PHPUNIT_RUN')) { + if (defined('PHPUNIT_RUN') || defined('CLI_TEST_RUN')) { \OC::$composerAutoloader->addPsr4($appNamespace . '\\Tests\\', $path . '/tests/', true); } |