no nested xml tags on dependencies

This commit is contained in:
Thomas Müller 2014-12-02 15:14:48 +01:00
parent eb81c52b95
commit b55ac514ac
4 changed files with 13 additions and 17 deletions

View File

@ -65,11 +65,11 @@ class DependencyAnalyzer {
}
private function analyseSupportedDatabases() {
if (!isset($this->dependencies['databases'])) {
if (!isset($this->dependencies['database'])) {
return;
}
$supportedDatabases = $this->dependencies['databases'];
$supportedDatabases = $this->dependencies['database'];
if (empty($supportedDatabases)) {
return;
}

View File

@ -23,7 +23,6 @@
"max-version": "5.5"
}
},
"databases": {
"database": [
{
"@attributes" : {
@ -31,8 +30,7 @@
},
"@value": "sqlite"},
"mysql"
]
},
],
"command": [
{
"@attributes" : {

View File

@ -21,10 +21,8 @@
<ocsid>166047</ocsid>
<dependencies>
<php min-version="5.4" max-version="5.5"/>
<databases>
<database min-version="3.0">sqlite</database>
<database>mysql</database>
</databases>
<command os="linux">grep</command>
<command os="windows">notepad.exe</command>
</dependencies>

View File

@ -77,7 +77,7 @@ class DependencyAnalyzer extends \PHPUnit_Framework_TestCase {
)
);
if (!is_null($databases)) {
$app['dependencies']['databases'] = $databases;
$app['dependencies']['database'] = $databases;
}
$analyser = new \OC\App\DependencyAnalyzer($app, $this->platformMock, $this->l10nMock);
$missing = $analyser->analyze();