diff options
author | diosmosis <diosmosis@users.noreply.github.com> | 2019-05-16 03:12:05 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-16 03:12:05 +0300 |
commit | 05017ba88ec611f63bf223728990351212ff560f (patch) | |
tree | 79c20127a6584a1316bb864b329d0cba713add10 /plugins/Login | |
parent | cecec674a65e4dc2a1aa7c33722a5380be2fd719 (diff) |
Require password confirmation before setting/removing superuser access. (#13975)
* Require password confirmation for changing superuser access and fix issue where getSiteAccess is called w/ superuser when toggling superuser access.
* apply review feedback
* Allow bypassing password confirmation in certain scenarios.
* Fixing tests & adding UI test.
* Update submodule.
* test fixes + remove return; from 2fa tests.
* update submodule
* Fixing tests
* Couple tweaks for screenshot testing.
* test fixes
* Fix TwoFactorAuthUsersManager test.
* More test fixes.
* try to disable all transitions
* More UI test fixes + disable materialize animations globally in UI tests.
* 2fa ui tests now working
Diffstat (limited to 'plugins/Login')
-rw-r--r-- | plugins/Login/tests/Integration/LoginTest.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/Login/tests/Integration/LoginTest.php b/plugins/Login/tests/Integration/LoginTest.php index 9f43512f0b..9ef38b17a9 100644 --- a/plugins/Login/tests/Integration/LoginTest.php +++ b/plugins/Login/tests/Integration/LoginTest.php @@ -15,6 +15,7 @@ use Piwik\DbHelper; use Piwik\NoAccessException; use Piwik\Plugins\Login\Auth; use Piwik\Plugins\UsersManager\API; +use Piwik\Plugins\UsersManager\UserUpdater; use Piwik\Tests\Framework\Mock\FakeAccess; use Piwik\Tests\Framework\TestCase\IntegrationTestCase; @@ -346,7 +347,8 @@ class LoginTest extends IntegrationTestCase private function _setUpSuperUserAccessViaDb() { - API::getInstance()->setSuperUserAccess('user', true); + $userUpdater = new UserUpdater(); + $userUpdater->setSuperUserAccessWithoutCurrentPassword('user', true); } private function authenticate($login, $tokenAuth) |