diff options
author | Roeland Jago Douma <rullzer@users.noreply.github.com> | 2019-01-29 19:50:15 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-29 19:50:15 +0100 |
commit | deb7d2364f38ce24bee62cd490fccfd6e4d3f059 (patch) | |
tree | 4c089bbc0adce35d42e53b06c3da74632718a371 /tests | |
parent | 050b9135d50f57c777c157bb7aa8c102524b2c77 (diff) | |
parent | ac8a6e22448cd4077e73b68731764bd60775665a (diff) | |
download | nextcloud-server-deb7d2364f38ce24bee62cd490fccfd6e4d3f059.tar.gz nextcloud-server-deb7d2364f38ce24bee62cd490fccfd6e4d3f059.zip |
Merge pull request #13869 from nextcloud/enh/clean_pending_2fa_session_on_password_change
Clean pending 2FA authentication on password reset
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Core/Controller/LostControllerTest.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/Core/Controller/LostControllerTest.php b/tests/Core/Controller/LostControllerTest.php index 2aa10cf1165..8635616a9d5 100644 --- a/tests/Core/Controller/LostControllerTest.php +++ b/tests/Core/Controller/LostControllerTest.php @@ -21,6 +21,7 @@ namespace Tests\Core\Controller; +use OC\Authentication\TwoFactorAuth\Manager; use OC\Core\Controller\LostController; use OC\Mail\Message; use OCP\AppFramework\Http\JSONResponse; @@ -77,6 +78,8 @@ class LostControllerTest extends \Test\TestCase { private $crypto; /** @var ILogger|\PHPUnit_Framework_MockObject_MockObject */ private $logger; + /** @var Manager|\PHPUnit_Framework_MockObject_MockObject */ + private $twofactorManager; protected function setUp() { parent::setUp(); @@ -128,6 +131,7 @@ class LostControllerTest extends \Test\TestCase { ->willReturn(true); $this->crypto = $this->createMock(ICrypto::class); $this->logger = $this->createMock(ILogger::class); + $this->twofactorManager = $this->createMock(Manager::class); $this->lostController = new LostController( 'Core', $this->request, @@ -142,7 +146,8 @@ class LostControllerTest extends \Test\TestCase { $this->mailer, $this->timeFactory, $this->crypto, - $this->logger + $this->logger, + $this->twofactorManager ); } |