Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/files_antivirus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorVictor Dubiniuk <victor.dubiniuk@gmail.com>2016-07-13 01:06:20 +0300
committerVictor Dubiniuk <victor.dubiniuk@gmail.com>2016-08-22 22:39:24 +0300
commit05de322f55b8c38f1620ec6cf5f964d9a18ceabb (patch)
treee13b4fc6f320c657edeb7229dacfdc9926157ebf /tests
parentbfd5d5bf4355c7242a3c4c9cc48a6232d3d12c87 (diff)
Fix file not found
Diffstat (limited to 'tests')
-rw-r--r--tests/cron/TaskTest.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/tests/cron/TaskTest.php b/tests/cron/TaskTest.php
index d6b0281..81c2d8d 100644
--- a/tests/cron/TaskTest.php
+++ b/tests/cron/TaskTest.php
@@ -15,9 +15,12 @@ use \OCA\Files_Antivirus\BackgroundScanner;
use OCA\Files_antivirus\Tests\TestBase;
class TaskTest extends TestBase {
+ /** @var ScannerFactory */
+ protected $scannerFactory;
+
public function setUp(){
parent::setUp();
- //Bgscanner requires at least one user on the current instance
+ //Background scanner requires at least one user on the current instance
$userManager = $this->application->getContainer()->query('ServerContainer')->getUserManager();
$results = $userManager->search('', 1, 0);
@@ -33,8 +36,9 @@ class TaskTest extends TestBase {
public function testRun(){
$backgroundScanner = new BackgroundScanner(
$this->scannerFactory,
- $this->container->query('ServerContainer')->getUserManager(),
- $this->l10n
+ $this->l10n,
+ $this->container->getServer()->getRootFolder(),
+ $this->container->getServer()->getUserSession()
);
$bgScan = $backgroundScanner->run();
$this->assertNull($bgScan);