]> source.dussan.org Git - nextcloud-server.git/commitdiff
Add the AppContainer
authorRoeland Jago Douma <roeland@famdouma.nl>
Wed, 22 Mar 2017 10:24:16 +0000 (11:24 +0100)
committerRoeland Jago Douma <roeland@famdouma.nl>
Wed, 22 Mar 2017 10:24:16 +0000 (11:24 +0100)
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
tests/lib/InfoXmlTest.php

index 4e75ca7820353db53a5fa667969df111bb745707..18391a20c03992e0115e800f7eaa0427ba794169 100644 (file)
@@ -63,6 +63,14 @@ class InfoXmlTest extends TestCase {
                $appPath = \OC_App::getAppPath($app);
                \OC_App::registerAutoloading($app, $appPath);
 
+               //Add the appcontainer
+               $applicationClassName = \OCP\AppFramework\App::buildAppNamespace($app) . '\\AppInfo\\Application';
+               if (class_exists($applicationClassName)) {
+                       $application = new $applicationClassName();
+               } else {
+                       $application = new \OCP\AppFramework\App($app);
+               }
+
                if (isset($appInfo['background-jobs'])) {
                        foreach ($appInfo['background-jobs'] as $job) {
                                $this->assertTrue(class_exists($job), 'Asserting background job "' . $job . '" exists');