diff options
Diffstat (limited to 'tests/lib/Remote/InstanceTest.php')
-rw-r--r-- | tests/lib/Remote/InstanceTest.php | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/tests/lib/Remote/InstanceTest.php b/tests/lib/Remote/InstanceTest.php index 3e4ffda15b7..560706e4572 100644 --- a/tests/lib/Remote/InstanceTest.php +++ b/tests/lib/Remote/InstanceTest.php @@ -1,4 +1,5 @@ <?php + /** * SPDX-FileCopyrightText: 2017 Nextcloud GmbH and Nextcloud contributors * SPDX-License-Identifier: AGPL-3.0-or-later @@ -24,7 +25,7 @@ class InstanceTest extends TestCase { $this->cache = new ArrayCache(); } - public function testBasicStatus() { + public function testBasicStatus(): void { $instance = new Instance('example.com', $this->cache, $this->getClientService()); $this->expectGetRequest('https://example.com/status.php', '{"installed":true,"maintenance":false,"needsDbUpgrade":false,"version":"13.0.0.5","versionstring":"13.0.0 alpha","edition":"","productname":"Nextcloud"}'); @@ -34,7 +35,7 @@ class InstanceTest extends TestCase { $this->assertEquals('https://example.com', $instance->getFullUrl()); } - public function testHttpFallback() { + public function testHttpFallback(): void { $instance = new Instance('example.com', $this->cache, $this->getClientService()); $this->expectGetRequest('https://example.com/status.php', new \Exception()); $this->expectGetRequest('http://example.com/status.php', '{"installed":true,"maintenance":false,"needsDbUpgrade":false,"version":"13.0.0.5","versionstring":"13.0.0 alpha","edition":"","productname":"Nextcloud"}'); @@ -43,7 +44,7 @@ class InstanceTest extends TestCase { $this->assertEquals('http://example.com', $instance->getFullUrl()); } - public function testRerequestHttps() { + public function testRerequestHttps(): void { $instance = new Instance('example.com', $this->cache, $this->getClientService()); $this->expectGetRequest('https://example.com/status.php', '{"installed":true,"maintenance":false,"needsDbUpgrade":false,"version":"13.0.0.5","versionstring":"13.0.0 alpha","edition":"","productname":"Nextcloud"}'); @@ -57,8 +58,8 @@ class InstanceTest extends TestCase { $this->assertEquals(false, $instance2->isActive()); } - - public function testPreventDowngradeAttach() { + + public function testPreventDowngradeAttach(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('refusing to connect to remote instance(example.com) over http that was previously accessible over https'); |