aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php')
-rw-r--r--tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php24
1 files changed, 8 insertions, 16 deletions
diff --git a/tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php b/tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php
index 02d72defa92..ea6ac682c70 100644
--- a/tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php
+++ b/tests/lib/Files/ObjectStore/ObjectStoreScannerTest.php
@@ -1,13 +1,8 @@
<?php
+
/**
- * ownCloud
- *
- * @author Joas Schilling
- * @copyright 2015 Joas Schilling nickvergessen@owncloud.com
- *
- * This file is licensed under the Affero General Public License version 3 or
- * later.
- * See the COPYING-README file.
+ * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace Test\Files\ObjectStore;
@@ -37,13 +32,11 @@ class ObjectStoreScannerTest extends TestCase {
$this->realScanner = new Scanner($this->storage);
}
- public function testFile() {
+ public function testFile(): void {
$data = "dummy file data\n";
$this->storage->file_put_contents('foo.txt', $data);
- $this->assertEquals(
- [],
- $this->scanner->scanFile('foo.txt'),
+ $this->assertNull($this->scanner->scanFile('foo.txt'),
'Asserting that no error occurred while scanFile()'
);
}
@@ -57,17 +50,16 @@ class ObjectStoreScannerTest extends TestCase {
$this->storage->file_put_contents('folder/bar.txt', $textData);
}
- public function testFolder() {
+ public function testFolder(): void {
$this->fillTestFolders();
- $this->assertEquals(
- [],
+ $this->assertNull(
$this->scanner->scan(''),
'Asserting that no error occurred while scan()'
);
}
- public function testBackgroundScan() {
+ public function testBackgroundScan(): void {
$this->fillTestFolders();
$this->storage->mkdir('folder2');
$this->storage->file_put_contents('folder2/bar.txt', 'foobar');