aboutsummaryrefslogtreecommitdiffstats
path: root/apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2016-11-18 15:42:30 +0100
committerGitHub <noreply@github.com>2016-11-18 15:42:30 +0100
commit332eaec4c01356d0b2119d4ec8fe07fa492d031b (patch)
tree3f89772129059801fd6768985aed9f7785a1791c /apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php
parentfaee255ff47873ed2f8908c7d6b6e603ded11618 (diff)
parent3ffd9a755f60761d6a1f5fa3d02d07b4c2e68972 (diff)
downloadnextcloud-server-332eaec4c01356d0b2119d4ec8fe07fa492d031b.tar.gz
nextcloud-server-332eaec4c01356d0b2119d4ec8fe07fa492d031b.zip
Merge pull request #1447 from nextcloud/password-confirmation-for-some-actions
Password confirmation for some actions
Diffstat (limited to 'apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php')
-rw-r--r--apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php b/apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php
index c7ac33467b3..8427c10e839 100644
--- a/apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php
+++ b/apps/twofactor_backupcodes/tests/Unit/Controller/SettingsControllerTest.php
@@ -24,6 +24,7 @@ namespace OCA\TwoFactorBackupCodes\Tests\Unit\Controller;
use OCA\TwoFactorBackupCodes\Controller\SettingsController;
use OCA\TwoFactorBackupCodes\Service\BackupCodeStorage;
+use OCP\AppFramework\Http\JSONResponse;
use OCP\IRequest;
use OCP\IUser;
use OCP\IUserSession;
@@ -89,7 +90,9 @@ class SettingsControllerTest extends TestCase {
'codes' => $codes,
'state' => 'state',
];
- $this->assertEquals($expected, $this->controller->createCodes());
+ $response = $this->controller->createCodes();
+ $this->assertInstanceOf(JSONResponse::class, $response);
+ $this->assertEquals($expected, $response->getData());
}
}