diff options
author | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2021-10-22 22:03:29 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2021-10-22 23:05:43 +0200 |
commit | e26d6f080ba978fb4c40b7caf190714a67e2e80c (patch) | |
tree | f5c7eb6aaa7cd61fb22763417368dca9f9aff6f3 /tests/lib/Accounts | |
parent | 6b099ecfe59402291b5915c928bfb16f4f9d6675 (diff) | |
download | nextcloud-server-e26d6f080ba978fb4c40b7caf190714a67e2e80c.tar.gz nextcloud-server-e26d6f080ba978fb4c40b7caf190714a67e2e80c.zip |
fix populating account array with missing default values
- both $userData and $defaultUserData have numeric indices
- each element contains at least the name and other fields
- appending the missing data array is sufficient
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
Diffstat (limited to 'tests/lib/Accounts')
-rw-r--r-- | tests/lib/Accounts/AccountManagerTest.php | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/tests/lib/Accounts/AccountManagerTest.php b/tests/lib/Accounts/AccountManagerTest.php index df1d62b3132..8bb60a1a516 100644 --- a/tests/lib/Accounts/AccountManagerTest.php +++ b/tests/lib/Accounts/AccountManagerTest.php @@ -516,8 +516,6 @@ class AccountManagerTest extends TestCase { 'value' => 'bob', 'verified' => IAccountManager::NOT_VERIFIED, ], - [], - [], [ 'name' => IAccountManager::PROPERTY_EMAIL, 'value' => 'bob@bob.bob', @@ -533,23 +531,23 @@ class AccountManagerTest extends TestCase { ], [ - 'name' => IAccountManager::PROPERTY_ADDRESS, - 'value' => '', - 'scope' => IAccountManager::SCOPE_LOCAL, + 'name' => IAccountManager::PROPERTY_EMAIL, + 'value' => 'bob@bob.bob', + 'scope' => IAccountManager::SCOPE_FEDERATED, 'verified' => IAccountManager::NOT_VERIFIED, ], [ - 'name' => IAccountManager::PROPERTY_WEBSITE, + 'name' => IAccountManager::PROPERTY_ADDRESS, 'value' => '', 'scope' => IAccountManager::SCOPE_LOCAL, 'verified' => IAccountManager::NOT_VERIFIED, ], [ - 'name' => IAccountManager::PROPERTY_EMAIL, - 'value' => 'bob@bob.bob', - 'scope' => IAccountManager::SCOPE_FEDERATED, + 'name' => IAccountManager::PROPERTY_WEBSITE, + 'value' => '', + 'scope' => IAccountManager::SCOPE_LOCAL, 'verified' => IAccountManager::NOT_VERIFIED, ], |