aboutsummaryrefslogtreecommitdiffstats
path: root/apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php')
-rw-r--r--apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php30
1 files changed, 6 insertions, 24 deletions
diff --git a/apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php b/apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php
index 9216be3ace5..423f932dcf5 100644
--- a/apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php
+++ b/apps/settings/tests/SetupChecks/AppDirsWithDifferentOwnerTest.php
@@ -3,27 +3,10 @@
declare(strict_types=1);
/**
- * @copyright Copyright (c) 2024 Côme Chilliet <come.chilliet@nextcloud.com>
- *
- * @author Côme Chilliet <come.chilliet@nextcloud.com>
- *
- * @license GNU AGPL version 3 or any later version
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Affero General Public License as
- * published by the Free Software Foundation, either version 3 of the
- * License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Affero General Public License for more details.
- *
- * You should have received a copy of the GNU Affero General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- *
+ * SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
*/
-namespace OCA\Settings\Tests;
+namespace OCA\Settings\Tests\SetupChecks;
use OCA\Settings\SetupChecks\AppDirsWithDifferentOwner;
use OCP\IL10N;
@@ -43,8 +26,7 @@ class AppDirsWithDifferentOwnerTest extends TestCase {
protected function setUp(): void {
parent::setUp();
- $this->l10n = $this->getMockBuilder(IL10N::class)
- ->disableOriginalConstructor()->getMock();
+ $this->l10n = $this->createMock(IL10N::class);
$this->l10n->expects($this->any())
->method('t')
->willReturnCallback(function ($message, array $replace) {
@@ -63,7 +45,7 @@ class AppDirsWithDifferentOwnerTest extends TestCase {
*
* @return void
*/
- public function testAppDirectoryOwnersOk() {
+ public function testAppDirectoryOwnersOk(): void {
$tempDir = tempnam(sys_get_temp_dir(), 'apps') . 'dir';
mkdir($tempDir);
mkdir($tempDir . DIRECTORY_SEPARATOR . 'app1');
@@ -90,7 +72,7 @@ class AppDirsWithDifferentOwnerTest extends TestCase {
*
* @return void
*/
- public function testAppDirectoryOwnersNotWritable() {
+ public function testAppDirectoryOwnersNotWritable(): void {
$tempDir = tempnam(sys_get_temp_dir(), 'apps') . 'dir';
\OC::$APPSROOTS = [
[