Fix tests

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2020-06-24 18:11:20 +02:00
parent 89ed2c37bf
commit a2f34f46b2
No known key found for this signature in database
GPG key ID: 7076EA9751AACDDA
5 changed files with 4 additions and 6 deletions

View file

@ -44,7 +44,6 @@ use OCP\Share\IManager;
use SearchDAV\Backend\SearchPropertyDefinition;
use SearchDAV\Query\Limit;
use SearchDAV\Query\Query;
use SearchDAV\XML\Operator;
use Test\TestCase;
class FileSearchBackendTest extends TestCase {
@ -258,7 +257,7 @@ class FileSearchBackendTest extends TestCase {
$this->assertEquals('/files/test/test/path', $result[0]->href);
}
public function testSearchInvalidProp() {
$this->expectException(\InvalidArgumentException::class);
@ -295,7 +294,7 @@ class FileSearchBackendTest extends TestCase {
return new Query($select, $from, $where, $orderBy, $limit);
}
public function testSearchNonFolder() {
$this->expectException(\InvalidArgumentException::class);

View file

@ -293,7 +293,7 @@ class ShareesAPIControllerTest extends TestCase {
$this->shareManager->expects($this->any())
->method('shareProviderExists')
->willReturnCallback(function ($shareType) use ($emailSharingEnabled) {
if ($shareType === \OCP\IShare::TYPE_EMAIL) {
if ($shareType === IShare::TYPE_EMAIL) {
return $emailSharingEnabled;
} else {
return false;

View file

@ -40,6 +40,7 @@ require_once __DIR__ . '/../appinfo/app.php';
use OC\Files\Storage\Temporary;
use OCP\IConfig;
use OCP\IUser;
use OCP\Share\IShare;
/**
* Class Test_Files_versions

View file

@ -37,7 +37,6 @@ use OCP\IGroupManager;
use OCP\IUser;
use OCP\IUserManager;
use OCP\IUserSession;
use OCP\Share;
use OCP\Share\IShare;
class UserPlugin implements ISearchPlugin {

View file

@ -13,7 +13,6 @@ use OC\Files\Node\HookConnector;
use OC\Files\Node\Root;
use OC\Files\Storage\Temporary;
use OC\Files\View;
use OCP\EventDispatcher\Event;
use OCP\EventDispatcher\GenericEvent as APIGenericEvent;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\Files\Events\Node\AbstractNodeEvent;