Skip to content
Prev Previous commit
Next Next commit
Fix ILogger instances in application tests for core parameters
Signed-off-by: Côme Chilliet <[email protected]>
  • Loading branch information
come-nc committed Mar 24, 2022
commit 25e7374e805307c100f169db7841a0e43dc43013
4 changes: 2 additions & 2 deletions apps/files/tests/BackgroundJob/ScanFilesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
use OCA\Files\BackgroundJob\ScanFiles;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\IConfig;
use OCP\ILogger;
use OCP\IUser;
use Psr\Log\LoggerInterface;
use Test\TestCase;
use Test\Traits\MountProviderTrait;
use Test\Traits\UserTrait;
Expand All @@ -54,7 +54,7 @@ protected function setUp(): void {

$config = $this->createMock(IConfig::class);
$dispatcher = $this->createMock(IEventDispatcher::class);
$logger = $this->createMock(ILogger::class);
$logger = $this->createMock(LoggerInterface::class);
$connection = \OC::$server->getDatabaseConnection();
$this->mountCache = \OC::$server->getUserMountCache();

Expand Down
4 changes: 2 additions & 2 deletions apps/files_sharing/tests/CapabilitiesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
use OCP\IConfig;
use OCP\IGroupManager;
use OCP\IL10N;
use OCP\ILogger;
use OCP\IURLGenerator;
use OCP\IUserManager;
use OCP\IUserSession;
Expand All @@ -46,6 +45,7 @@
use OCP\Security\IHasher;
use OCP\Security\ISecureRandom;
use OCP\Share\IProviderFactory;
use Psr\Log\LoggerInterface;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;

/**
Expand Down Expand Up @@ -79,7 +79,7 @@ private function getResults(array $map) {
$config = $this->getMockBuilder(IConfig::class)->disableOriginalConstructor()->getMock();
$config->method('getAppValue')->willReturnMap($map);
$shareManager = new Manager(
$this->createMock(ILogger::class),
$this->createMock(LoggerInterface::class),
$config,
$this->createMock(ISecureRandom::class),
$this->createMock(IHasher::class),
Expand Down