From: Christoph Wurst Date: Thu, 16 Jun 2016 09:07:44 +0000 (+0200) Subject: assert app is loaded in unit tests X-Git-Tag: v9.1.0RC1~68^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=3521f974db2cf7bebac66ab4c987bb3c67d5d02f;p=nextcloud-server.git assert app is loaded in unit tests --- diff --git a/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php b/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php index 283ba7f9424..586fd3aaa2e 100644 --- a/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php +++ b/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php @@ -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')