]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix unit tests
authorRoeland Jago Douma <rullzer@owncloud.com>
Thu, 4 Feb 2016 11:07:25 +0000 (12:07 +0100)
committerBjörn Schießle <bjoern@schiessle.org>
Mon, 8 Feb 2016 10:30:48 +0000 (11:30 +0100)
tests/lib/app.php
tests/lib/app/manager.php

index 389c9e5d2cf40c27ceffea2f7b5437ebc82241ec..3fb42ea23829de8653d575d55dc4fcb2d7a133b9 100644 (file)
@@ -312,6 +312,7 @@ class Test_App extends \Test\TestCase {
                                        'appforgroup1',
                                        'appforgroup12',
                                        'dav',
+                                       'federatedfilesharing',
                                ),
                                false
                        ),
@@ -325,6 +326,7 @@ class Test_App extends \Test\TestCase {
                                        'appforgroup12',
                                        'appforgroup2',
                                        'dav',
+                                       'federatedfilesharing',
                                ),
                                false
                        ),
@@ -339,6 +341,7 @@ class Test_App extends \Test\TestCase {
                                        'appforgroup12',
                                        'appforgroup2',
                                        'dav',
+                                       'federatedfilesharing',
                                ),
                                false
                        ),
@@ -353,6 +356,7 @@ class Test_App extends \Test\TestCase {
                                        'appforgroup12',
                                        'appforgroup2',
                                        'dav',
+                                       'federatedfilesharing',
                                ),
                                false,
                        ),
@@ -367,6 +371,7 @@ class Test_App extends \Test\TestCase {
                                        'appforgroup12',
                                        'appforgroup2',
                                        'dav',
+                                       'federatedfilesharing',
                                ),
                                true,
                        ),
@@ -444,11 +449,11 @@ class Test_App extends \Test\TestCase {
                        );
 
                $apps = \OC_App::getEnabledApps(true);
-               $this->assertEquals(array('files', 'app3', 'dav'), $apps);
+               $this->assertEquals(array('files', 'app3', 'dav', 'federatedfilesharing',), $apps);
 
                // mock should not be called again here
                $apps = \OC_App::getEnabledApps(false);
-               $this->assertEquals(array('files', 'app3', 'dav'), $apps);
+               $this->assertEquals(array('files', 'app3', 'dav', 'federatedfilesharing',), $apps);
 
                $this->restoreAppConfig();
                \OC_User::setUserId(null);
index f82f1049ce376078259f2793ed109e892a801eb1..ee9b1f308ea8b65ee8b1bdb0ccb97dfab710c5c6 100644 (file)
@@ -282,7 +282,7 @@ class Manager extends TestCase {
                $this->appConfig->setValue('test1', 'enabled', 'yes');
                $this->appConfig->setValue('test2', 'enabled', 'no');
                $this->appConfig->setValue('test3', 'enabled', '["foo"]');
-               $this->assertEquals(['dav', 'files', 'test1', 'test3'], $this->manager->getInstalledApps());
+               $this->assertEquals(['dav', 'federatedfilesharing', 'files', 'test1', 'test3'], $this->manager->getInstalledApps());
        }
 
        public function testGetAppsForUser() {
@@ -296,7 +296,7 @@ class Manager extends TestCase {
                $this->appConfig->setValue('test2', 'enabled', 'no');
                $this->appConfig->setValue('test3', 'enabled', '["foo"]');
                $this->appConfig->setValue('test4', 'enabled', '["asd"]');
-               $this->assertEquals(['dav', 'files', 'test1', 'test3'], $this->manager->getEnabledAppsForUser($user));
+               $this->assertEquals(['dav', 'federatedfilesharing', 'files', 'test1', 'test3'], $this->manager->getEnabledAppsForUser($user));
        }
 
        public function testGetAppsNeedingUpgrade() {
@@ -308,6 +308,7 @@ class Manager extends TestCase {
                $appInfos = [
                        'dav' => ['id' => 'dav'],
                        'files' => ['id' => 'files'],
+                       'federatedfilesharing' => ['id' => 'federatedfilesharing'],
                        'test1' => ['id' => 'test1', 'version' => '1.0.1', 'requiremax' => '9.0.0'],
                        'test2' => ['id' => 'test2', 'version' => '1.0.0', 'requiremin' => '8.2.0'],
                        'test3' => ['id' => 'test3', 'version' => '1.2.4', 'requiremin' => '9.0.0'],
@@ -348,6 +349,7 @@ class Manager extends TestCase {
                $appInfos = [
                        'dav' => ['id' => 'dav'],
                        'files' => ['id' => 'files'],
+                       'federatedfilesharing' => ['id' => 'federatedfilesharing'],
                        'test1' => ['id' => 'test1', 'version' => '1.0.1', 'requiremax' => '8.0.0'],
                        'test2' => ['id' => 'test2', 'version' => '1.0.0', 'requiremin' => '8.2.0'],
                        'test3' => ['id' => 'test3', 'version' => '1.2.4', 'requiremin' => '9.0.0'],