|
|
|
|
@ -99,7 +99,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
], |
|
|
|
|
], |
|
|
|
|
]); |
|
|
|
|
$user->expects($this->once()) |
|
|
|
|
$user->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user123'); |
|
|
|
|
|
|
|
|
|
@ -129,7 +129,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
], |
|
|
|
|
], |
|
|
|
|
]); |
|
|
|
|
$user->expects($this->once()) |
|
|
|
|
$user->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user123'); |
|
|
|
|
|
|
|
|
|
@ -157,7 +157,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
'PHOTO' => base64_encode('photophotophoto'), |
|
|
|
|
], |
|
|
|
|
]); |
|
|
|
|
$user->expects($this->once()) |
|
|
|
|
$user->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user123'); |
|
|
|
|
|
|
|
|
|
@ -186,7 +186,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
'PHOTO' => 'VALUE=uri:https://photo', |
|
|
|
|
], |
|
|
|
|
]); |
|
|
|
|
$user->expects($this->once()) |
|
|
|
|
$user->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user123'); |
|
|
|
|
|
|
|
|
|
@ -210,7 +210,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -253,7 +253,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -332,7 +332,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -411,7 +411,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -469,7 +469,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -555,7 +555,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -624,7 +624,7 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
|
|
|
|
|
/** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */ |
|
|
|
|
$currentUser = $this->createMock(IUser::class); |
|
|
|
|
$currentUser->expects($this->once()) |
|
|
|
|
$currentUser->expects($this->exactly(2)) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user001'); |
|
|
|
|
|
|
|
|
|
@ -963,9 +963,8 @@ class ContactsStoreTest extends TestCase { |
|
|
|
|
'isLocalSystemBook' => false |
|
|
|
|
], |
|
|
|
|
]); |
|
|
|
|
$user->expects($this->once()) |
|
|
|
|
->method('getUID') |
|
|
|
|
->willReturn('user123'); |
|
|
|
|
$user->expects($this->never()) |
|
|
|
|
->method('getUID'); |
|
|
|
|
|
|
|
|
|
$entry = $this->contactsStore->findOne($user, 0, 'a567'); |
|
|
|
|
|
|
|
|
|
|