summaryrefslogtreecommitdiffstats
path: root/apps/provisioning_api/tests
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2020-10-05 21:30:27 +0200
committerGitHub <noreply@github.com>2020-10-05 21:30:27 +0200
commit1ad0631c661b64d670f1a61dfd46b7de2addb8d8 (patch)
treea44a96a5bcddced97f72160ac0d6b52a232127b9 /apps/provisioning_api/tests
parentd357f4b10fe1b59e1e07bb90641d647522c7bfe2 (diff)
parent62923a5e1eb5369dd5a89cd7b7928b13a8a61c6a (diff)
downloadnextcloud-server-1ad0631c661b64d670f1a61dfd46b7de2addb8d8.tar.gz
nextcloud-server-1ad0631c661b64d670f1a61dfd46b7de2addb8d8.zip
Merge pull request #23182 from sharidas/fix-user-emailaddr
Fix the user email issue while creating a user
Diffstat (limited to 'apps/provisioning_api/tests')
-rw-r--r--apps/provisioning_api/tests/Controller/UsersControllerTest.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/provisioning_api/tests/Controller/UsersControllerTest.php b/apps/provisioning_api/tests/Controller/UsersControllerTest.php
index fec7fc9f135..d508670d4f6 100644
--- a/apps/provisioning_api/tests/Controller/UsersControllerTest.php
+++ b/apps/provisioning_api/tests/Controller/UsersControllerTest.php
@@ -500,9 +500,13 @@ class UsersControllerTest extends TestCase {
->method('userExists')
->with('NewUser')
->willReturn(false);
+ $newUser = $this->createMock(IUser::class);
+ $newUser->expects($this->once())
+ ->method('setEMailAddress');
$this->userManager
->expects($this->once())
- ->method('createUser');
+ ->method('createUser')
+ ->willReturn($newUser);
$this->logger
->expects($this->once())
->method('info')