diff options
author | Julius Härtl <jus@bitgrid.net> | 2020-10-07 12:32:16 +0200 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2020-12-14 11:14:59 +0100 |
commit | 102402bfcbad8a0c1730b4d88172bcee28c50df7 (patch) | |
tree | 65893ae342b53f7529d70ea10548c5b62ccae5e2 /apps/files_sharing/tests | |
parent | 131fcac91ed0468d6564eb268c85b6665e06f330 (diff) | |
download | nextcloud-server-102402bfcbad8a0c1730b4d88172bcee28c50df7.tar.gz nextcloud-server-102402bfcbad8a0c1730b4d88172bcee28c50df7.zip |
Show unique displayname context in the user share list entries
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps/files_sharing/tests')
-rw-r--r-- | apps/files_sharing/tests/Controller/ShareAPIControllerTest.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php b/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php index a2a6ab59809..ff3429ca71c 100644 --- a/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php +++ b/apps/files_sharing/tests/Controller/ShareAPIControllerTest.php @@ -583,6 +583,7 @@ class ShareAPIControllerTest extends TestCase { 'share_type' => IShare::TYPE_USER, 'share_with' => 'userId', 'share_with_displayname' => 'userDisplay', + 'share_with_displayname_unique' => 'userId@example.com', 'uid_owner' => 'initiatorId', 'displayname_owner' => 'initiatorDisplay', 'item_type' => 'file', @@ -782,6 +783,7 @@ class ShareAPIControllerTest extends TestCase { $user = $this->getMockBuilder(IUser::class)->getMock(); $user->method('getUID')->willReturn('userId'); $user->method('getDisplayName')->willReturn('userDisplay'); + $user->method('getEMailAddress')->willReturn('userId@example.com'); $group = $this->getMockBuilder('OCP\IGroup')->getMock(); $group->method('getGID')->willReturn('groupId'); @@ -3440,6 +3442,8 @@ class ShareAPIControllerTest extends TestCase { $initiator->method('getDisplayName')->willReturn('initiatorDN'); $recipient = $this->getMockBuilder(IUser::class)->getMock(); $recipient->method('getDisplayName')->willReturn('recipientDN'); + $recipient->method('getEmailAddress')->willReturn('recipient'); + $result = []; @@ -3479,6 +3483,7 @@ class ShareAPIControllerTest extends TestCase { 'file_target' => 'myTarget', 'share_with' => 'recipient', 'share_with_displayname' => 'recipient', + 'share_with_displayname_unique' => 'recipient', 'note' => 'personal note', 'label' => null, 'mail_send' => 0, @@ -3516,6 +3521,7 @@ class ShareAPIControllerTest extends TestCase { 'file_target' => 'myTarget', 'share_with' => 'recipient', 'share_with_displayname' => 'recipientDN', + 'share_with_displayname_unique' => 'recipient', 'mail_send' => 0, 'mimetype' => 'myMimeType', 'has_preview' => false, @@ -3567,6 +3573,7 @@ class ShareAPIControllerTest extends TestCase { 'file_target' => 'myTarget', 'share_with' => 'recipient', 'share_with_displayname' => 'recipient', + 'share_with_displayname_unique' => 'recipient', 'mail_send' => 0, 'mimetype' => 'myMimeType', 'has_preview' => false, @@ -3614,6 +3621,7 @@ class ShareAPIControllerTest extends TestCase { 'file_target' => 'myTarget', 'share_with' => 'recipient', 'share_with_displayname' => 'recipient', + 'share_with_displayname_unique' => 'recipient', 'mail_send' => 0, 'mimetype' => 'myMimeType', 'has_preview' => false, @@ -4162,6 +4170,7 @@ class ShareAPIControllerTest extends TestCase { 'file_target' => 'myTarget', 'share_with' => 'recipient', 'share_with_displayname' => 'recipient', + 'share_with_displayname_unique' => 'recipient', 'mail_send' => 0, 'mimetype' => 'mimeWithPreview', 'has_preview' => true, |