aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Http/WellKnown/RequestManagerTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/Http/WellKnown/RequestManagerTest.php')
-rw-r--r--tests/lib/Http/WellKnown/RequestManagerTest.php35
1 files changed, 9 insertions, 26 deletions
diff --git a/tests/lib/Http/WellKnown/RequestManagerTest.php b/tests/lib/Http/WellKnown/RequestManagerTest.php
index 1fa92804cfa..3ab6cb190b2 100644
--- a/tests/lib/Http/WellKnown/RequestManagerTest.php
+++ b/tests/lib/Http/WellKnown/RequestManagerTest.php
@@ -2,25 +2,9 @@
declare(strict_types=1);
-/*
- * @copyright 2020 Christoph Wurst <christoph@winzerhof-wurst.at>
- *
- * @author 2020 Christoph Wurst <christoph@winzerhof-wurst.at>
- *
- * @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: 2020 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace Test\Http\WellKnown;
@@ -43,7 +27,6 @@ use Test\TestCase;
use function get_class;
class RequestManagerTest extends TestCase {
-
/** @var Coordinator|MockObject */
private $coordinator;
@@ -74,7 +57,7 @@ class RequestManagerTest extends TestCase {
$request = $this->createMock(IRequest::class);
$this->expectException(RuntimeException::class);
- $this->manager->process("webfinger", $request);
+ $this->manager->process('webfinger', $request);
}
public function testProcessNoHandlersRegistered(): void {
@@ -87,7 +70,7 @@ class RequestManagerTest extends TestCase {
->method('getWellKnownHandlers')
->willReturn([]);
- $response = $this->manager->process("webfinger", $request);
+ $response = $this->manager->process('webfinger', $request);
self::assertNull($response);
}
@@ -108,11 +91,11 @@ class RequestManagerTest extends TestCase {
$this->container->expects(self::once())
->method('get')
->with(get_class($handler))
- ->willThrowException(new QueryException(""));
+ ->willThrowException(new QueryException(''));
$this->logger->expects(self::once())
->method('error');
- $response = $this->manager->process("webfinger", $request);
+ $response = $this->manager->process('webfinger', $request);
self::assertNull($response);
}
@@ -137,7 +120,7 @@ class RequestManagerTest extends TestCase {
$this->logger->expects(self::once())
->method('error');
- $response = $this->manager->process("webfinger", $request);
+ $response = $this->manager->process('webfinger', $request);
self::assertNull($response);
}
@@ -163,7 +146,7 @@ class RequestManagerTest extends TestCase {
->with(get_class($handler))
->willReturn($handler);
- $response = $this->manager->process("webfinger", $request);
+ $response = $this->manager->process('webfinger', $request);
self::assertNotNull($response);
self::assertInstanceOf(JrdResponse::class, $response);