summaryrefslogtreecommitdiffstats
path: root/tests/lib/Contacts/ContactsMenu
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/Contacts/ContactsMenu')
-rw-r--r--tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php9
-rw-r--r--tests/lib/Contacts/ContactsMenu/ContactsStoreTest.php33
-rw-r--r--tests/lib/Contacts/ContactsMenu/ManagerTest.php9
-rw-r--r--tests/lib/Contacts/ContactsMenu/Providers/EMailproviderTest.php5
4 files changed, 26 insertions, 30 deletions
diff --git a/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php b/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
index ee053ce40e5..f20df96f7a2 100644
--- a/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
+++ b/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
@@ -33,18 +33,17 @@ use OCP\Contacts\ContactsMenu\IProvider;
use OCP\ILogger;
use OCP\IServerContainer;
use OCP\IUser;
-use PHPUnit_Framework_MockObject_MockObject;
use Test\TestCase;
class ActionProviderStoreTest extends TestCase {
- /** @var IServerContainer|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IServerContainer|\PHPUnit\Framework\MockObject\MockObject */
private $serverContainer;
- /** @var IAppManager|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IAppManager|\PHPUnit\Framework\MockObject\MockObject */
private $appManager;
- /** @var ILogger|PHPUnit_Framework_MockObject_MockObject */
+ /** @var ILogger|\PHPUnit\Framework\MockObject\MockObject */
private $logger;
/** @var ActionProviderStore */
@@ -114,7 +113,7 @@ class ActionProviderStoreTest extends TestCase {
$this->assertInstanceOf(EMailProvider::class, $providers[0]);
}
-
+
public function testGetProvidersWithQueryException() {
$this->expectException(\Exception::class);
diff --git a/tests/lib/Contacts/ContactsMenu/ContactsStoreTest.php b/tests/lib/Contacts/ContactsMenu/ContactsStoreTest.php
index 245c89c3228..acfe83ac558 100644
--- a/tests/lib/Contacts/ContactsMenu/ContactsStoreTest.php
+++ b/tests/lib/Contacts/ContactsMenu/ContactsStoreTest.php
@@ -31,19 +31,18 @@ use OCP\IConfig;
use OCP\IGroupManager;
use OCP\IUser;
use OCP\IUserManager;
-use PHPUnit_Framework_MockObject_MockObject;
use Test\TestCase;
class ContactsStoreTest extends TestCase {
/** @var ContactsStore */
private $contactsStore;
- /** @var IManager|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IManager|\PHPUnit\Framework\MockObject\MockObject */
private $contactsManager;
- /** @var IUserManager|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IUserManager|\PHPUnit\Framework\MockObject\MockObject */
private $userManager;
- /** @var IGroupManager|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IGroupManager|\PHPUnit\Framework\MockObject\MockObject */
private $groupManager;
- /** @var IConfig|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IConfig|\PHPUnit\Framework\MockObject\MockObject */
private $config;
protected function setUp(): void {
@@ -57,7 +56,7 @@ class ContactsStoreTest extends TestCase {
}
public function testGetContactsWithoutFilter() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -87,7 +86,7 @@ class ContactsStoreTest extends TestCase {
}
public function testGetContactsHidesOwnEntry() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -114,7 +113,7 @@ class ContactsStoreTest extends TestCase {
}
public function testGetContactsWithoutBinaryImage() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -143,7 +142,7 @@ class ContactsStoreTest extends TestCase {
}
public function testGetContactsWithoutAvatarURI() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -196,7 +195,7 @@ class ContactsStoreTest extends TestCase {
->with($this->equalTo('core'), $this->equalTo('shareapi_exclude_groups_list'), $this->equalTo(''))
->willReturn('["group1", "group5", "group6"]');
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $currentUser */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */
$currentUser = $this->createMock(IUser::class);
$currentUser->expects($this->once())
->method('getUID')
@@ -246,7 +245,7 @@ class ContactsStoreTest extends TestCase {
->with($this->equalTo('core'), $this->equalTo('shareapi_only_share_with_group_members'), $this->equalTo('no'))
->willReturn('yes');
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $currentUser */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */
$currentUser = $this->createMock(IUser::class);
$currentUser->expects($this->once())
->method('getUID')
@@ -332,7 +331,7 @@ class ContactsStoreTest extends TestCase {
->with($this->equalTo('core'), $this->equalTo('shareapi_only_share_with_group_members'), $this->equalTo('no'))
->willReturn('no');
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $currentUser */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $currentUser */
$currentUser = $this->createMock(IUser::class);
$currentUser->expects($this->once())
->method('getUID')
@@ -405,7 +404,7 @@ class ContactsStoreTest extends TestCase {
->with($this->equalTo('core'), $this->equalTo('shareapi_allow_share_dialog_user_enumeration'), $this->equalTo('yes'))
->willReturn('no');
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->any())
->method('search')
@@ -489,7 +488,7 @@ class ContactsStoreTest extends TestCase {
->with($this->equalTo('core'), $this->equalTo('shareapi_allow_share_dialog_user_enumeration'), $this->equalTo('yes'))
->willReturn('yes');
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -520,7 +519,7 @@ class ContactsStoreTest extends TestCase {
}
public function testFindOneEMail() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
@@ -551,7 +550,7 @@ class ContactsStoreTest extends TestCase {
}
public function testFindOneNotSupportedType() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$entry = $this->contactsStore->findOne($user, 42, 'darren@roner.au');
@@ -560,7 +559,7 @@ class ContactsStoreTest extends TestCase {
}
public function testFindOneNoMatches() {
- /** @var IUser|PHPUnit_Framework_MockObject_MockObject $user */
+ /** @var IUser|\PHPUnit\Framework\MockObject\MockObject $user */
$user = $this->createMock(IUser::class);
$this->contactsManager->expects($this->once())
->method('search')
diff --git a/tests/lib/Contacts/ContactsMenu/ManagerTest.php b/tests/lib/Contacts/ContactsMenu/ManagerTest.php
index 561051974b7..4cfbd9c7c90 100644
--- a/tests/lib/Contacts/ContactsMenu/ManagerTest.php
+++ b/tests/lib/Contacts/ContactsMenu/ManagerTest.php
@@ -32,21 +32,20 @@ use OCP\Contacts\ContactsMenu\IEntry;
use OCP\Contacts\ContactsMenu\IProvider;
use OCP\IConfig;
use OCP\IUser;
-use PHPUnit_Framework_MockObject_MockObject;
use Test\TestCase;
class ManagerTest extends TestCase {
- /** @var ContactsStore|PHPUnit_Framework_MockObject_MockObject */
+ /** @var ContactsStore|\PHPUnit\Framework\MockObject\MockObject */
private $contactsStore;
- /** @var IAppManager|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IAppManager|\PHPUnit\Framework\MockObject\MockObject */
private $appManager;
- /** @var IConfig|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IConfig|\PHPUnit\Framework\MockObject\MockObject */
private $config;
- /** @var ActionProviderStore|PHPUnit_Framework_MockObject_MockObject */
+ /** @var ActionProviderStore|\PHPUnit\Framework\MockObject\MockObject */
private $actionProviderStore;
/** @var Manager */
diff --git a/tests/lib/Contacts/ContactsMenu/Providers/EMailproviderTest.php b/tests/lib/Contacts/ContactsMenu/Providers/EMailproviderTest.php
index 157f8574fa4..c0052469aba 100644
--- a/tests/lib/Contacts/ContactsMenu/Providers/EMailproviderTest.php
+++ b/tests/lib/Contacts/ContactsMenu/Providers/EMailproviderTest.php
@@ -29,15 +29,14 @@ use OCP\Contacts\ContactsMenu\IActionFactory;
use OCP\Contacts\ContactsMenu\IEntry;
use OCP\Contacts\ContactsMenu\ILinkAction;
use OCP\IURLGenerator;
-use PHPUnit_Framework_MockObject_MockObject;
use Test\TestCase;
class EMailproviderTest extends TestCase {
- /** @var IActionFactory|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IActionFactory|\PHPUnit\Framework\MockObject\MockObject */
private $actionFactory;
- /** @var IURLGenerator|PHPUnit_Framework_MockObject_MockObject */
+ /** @var IURLGenerator|\PHPUnit\Framework\MockObject\MockObject */
private $urlGenerator;
/** @var EMailProvider */