Return the autoupdater value from the server

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2016-09-27 15:06:59 +02:00
parent abce80b55a
commit 182f6ec6c6
No known key found for this signature in database
GPG Key ID: E166FD8976B3BAC8
2 changed files with 5 additions and 0 deletions

View File

@ -174,6 +174,7 @@ class Updater extends BasicEmitter {
$tmp['versionstring'] = (string)$data->versionstring;
$tmp['url'] = (string)$data->url;
$tmp['web'] = (string)$data->web;
$tmp['autoupdater'] = (string)$data->autoupdater;
} else {
libxml_clear_errors();
}

View File

@ -212,6 +212,7 @@ class UpdaterTest extends \Test\TestCase {
'versionstring' => 'ownCloud 8.0.4',
'url' => 'https://download.owncloud.org/community/owncloud-8.0.4.zip',
'web' => 'http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html',
'autoupdater' => '0',
];
$this->config
@ -249,6 +250,7 @@ class UpdaterTest extends \Test\TestCase {
<versionstring>ownCloud 8.0.4</versionstring>
<url>https://download.owncloud.org/community/owncloud-8.0.4.zip</url>
<web>http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html</web>
<autoupdater>0</autoupdater>
</owncloud>';
$this->httpHelper
->expects($this->once())
@ -305,6 +307,7 @@ class UpdaterTest extends \Test\TestCase {
'versionstring' => '',
'url' => '',
'web' => '',
'autoupdater' => '',
];
$this->config
@ -338,6 +341,7 @@ class UpdaterTest extends \Test\TestCase {
<versionstring></versionstring>
<url></url>
<web></web>
<autoupdater></autoupdater>
</owncloud>';
$this->httpHelper
->expects($this->once())