]> source.dussan.org Git - nextcloud-server.git/commitdiff
assert app is loaded in unit tests
authorChristoph Wurst <christoph@owncloud.com>
Thu, 16 Jun 2016 09:07:44 +0000 (11:07 +0200)
committerChristoph Wurst <christoph@owncloud.com>
Thu, 16 Jun 2016 09:08:43 +0000 (11:08 +0200)
tests/lib/Authentication/TwoFactorAuth/ManagerTest.php

index 283ba7f9424eae327a75ea96fc8df6bc6c871737..586fd3aaa2e8a5f30175e11785c35a973ae2f70d 100644 (file)
@@ -86,6 +86,10 @@ class ManagerTest extends TestCase {
                                                '\OCA\MyCustom2faApp\FakeProvider',
                                        ],
                ]));
+
+               $this->manager->expects($this->once())
+                       ->method('loadTwoFactorApp')
+                       ->with('mycustom2faapp');
        }
 
        /**
@@ -97,6 +101,9 @@ class ManagerTest extends TestCase {
                        ->method('getEnabledAppsForUser')
                        ->with($this->user)
                        ->will($this->returnValue(['faulty2faapp']));
+               $this->manager->expects($this->once())
+                       ->method('loadTwoFactorApp')
+                       ->with('faulty2faapp');
 
                $this->appManager->expects($this->once())
                        ->method('getAppInfo')