]> source.dussan.org Git - nextcloud-server.git/commitdiff
Change updater URL 1323/head
authorJoas Schilling <coding@schilljs.com>
Thu, 8 Sep 2016 10:20:29 +0000 (12:20 +0200)
committerJoas Schilling <coding@schilljs.com>
Thu, 8 Sep 2016 10:30:17 +0000 (12:30 +0200)
config/config.sample.php
lib/private/Updater/VersionCheck.php
tests/lib/Updater/VersionCheckTest.php

index 2b39e93aadebf2ceb4c5a199dbcbd4fb64049174..d6680caac18a591415980a933eb1dd4375bdc45d 100644 (file)
@@ -519,7 +519,7 @@ $CONFIG = array(
 /**
  * URL that Nextcloud should use to look for updates
  */
-'updater.server.url' => 'https://updates.nextcloud.org/server/',
+'updater.server.url' => 'https://updates.nextcloud.com/update-server/',
 
 /**
  * Is Nextcloud connected to the Internet or running in a closed network?
index 88ba9b63fa3bd0993c1c4db0e15bb2260f73a539..e846052a300df77291905eaab1de54722f9459b1 100644 (file)
@@ -59,7 +59,7 @@ class VersionCheck {
                        return json_decode($this->config->getAppValue('core', 'lastupdateResult'), true);
                }
 
-               $updaterUrl = $this->config->getSystemValue('updater.server.url', 'https://updates.nextcloud.com/server/');
+               $updaterUrl = $this->config->getSystemValue('updater.server.url', 'https://updates.nextcloud.com/update-server/');
 
                $this->config->setAppValue('core', 'lastupdatedat', time());
 
index e9b915f1508535377d3049429cb23a2d9d85cc67..d6b457da8a2cadf767fed62d4feb9c29dd4aa1d7 100644 (file)
@@ -93,8 +93,8 @@ class VersionCheckTest extends \Test\TestCase {
                $this->config
                        ->expects($this->at(1))
                        ->method('getSystemValue')
-                       ->with('updater.server.url', 'https://updates.nextcloud.com/server/')
-                       ->willReturn('https://updates.nextcloud.com/server/');
+                       ->with('updater.server.url', 'https://updates.nextcloud.com/update-server/')
+                       ->willReturnArgument(1);
                $this->config
                        ->expects($this->at(2))
                        ->method('setAppValue')
@@ -124,7 +124,7 @@ class VersionCheckTest extends \Test\TestCase {
                $this->updater
                        ->expects($this->once())
                        ->method('getUrlContent')
-                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/server/'))
+                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/update-server/'))
                        ->will($this->returnValue($updateXml));
 
                $this->assertSame($expectedResult, $this->updater->check());
@@ -139,8 +139,8 @@ class VersionCheckTest extends \Test\TestCase {
                $this->config
                        ->expects($this->at(1))
                        ->method('getSystemValue')
-                       ->with('updater.server.url', 'https://updates.nextcloud.com/server/')
-                       ->willReturn('https://updates.nextcloud.com/server/');
+                       ->with('updater.server.url', 'https://updates.nextcloud.com/update-server/')
+                       ->willReturnArgument(1);
                $this->config
                        ->expects($this->at(2))
                        ->method('setAppValue')
@@ -164,7 +164,7 @@ class VersionCheckTest extends \Test\TestCase {
                $this->updater
                        ->expects($this->once())
                        ->method('getUrlContent')
-                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/server/'))
+                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/update-server/'))
                        ->will($this->returnValue($updateXml));
 
                $this->assertSame([], $this->updater->check());
@@ -186,8 +186,8 @@ class VersionCheckTest extends \Test\TestCase {
                $this->config
                        ->expects($this->at(1))
                        ->method('getSystemValue')
-                       ->with('updater.server.url', 'https://updates.nextcloud.com/server/')
-                       ->willReturn('https://updates.nextcloud.com/server/');
+                       ->with('updater.server.url', 'https://updates.nextcloud.com/update-server/')
+                       ->willReturnArgument(1);
                $this->config
                        ->expects($this->at(2))
                        ->method('setAppValue')
@@ -213,7 +213,7 @@ class VersionCheckTest extends \Test\TestCase {
                $this->updater
                        ->expects($this->once())
                        ->method('getUrlContent')
-                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/server/'))
+                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/update-server/'))
                        ->will($this->returnValue($updateXml));
 
                $this->assertSame($expectedResult, $this->updater->check());
@@ -230,8 +230,8 @@ class VersionCheckTest extends \Test\TestCase {
                $this->config
                        ->expects($this->at(1))
                        ->method('getSystemValue')
-                       ->with('updater.server.url', 'https://updates.nextcloud.com/server/')
-                       ->willReturn('https://updates.nextcloud.com/server/');
+                       ->with('updater.server.url', 'https://updates.nextcloud.com/update-server/')
+                       ->willReturnArgument(1);
                $this->config
                        ->expects($this->at(2))
                        ->method('setAppValue')
@@ -255,7 +255,7 @@ class VersionCheckTest extends \Test\TestCase {
                $this->updater
                        ->expects($this->once())
                        ->method('getUrlContent')
-                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/server/'))
+                       ->with($this->buildUpdateUrl('https://updates.nextcloud.com/update-server/'))
                        ->will($this->returnValue($updateXml));
 
                $this->assertSame($expectedResult, $this->updater->check());