mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-31 01:34:09 +02:00
Merge pull request #3779 from Icinga/fix/broken-tests-if-module-requires-its-own-config
tests: Don't include non-enabled modules
This commit is contained in:
commit
bc1371bad7
@ -188,7 +188,9 @@ class PhpCommand extends Command
|
|||||||
{
|
{
|
||||||
$modulePaths = [];
|
$modulePaths = [];
|
||||||
foreach (Icinga::app()->getModuleManager()->getModuleInfo() as $module) {
|
foreach (Icinga::app()->getModuleManager()->getModuleInfo() as $module) {
|
||||||
$modulePaths[] = $module->path;
|
if (! file_exists($module->path . '/phpunit.xml')) {
|
||||||
|
$modulePaths[] = $module->path;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$vars = array();
|
$vars = array();
|
||||||
@ -247,7 +249,7 @@ class PhpCommand extends Command
|
|||||||
|
|
||||||
foreach ($app->getModuleManager()->getModuleInfo() as $module) {
|
foreach ($app->getModuleManager()->getModuleInfo() as $module) {
|
||||||
$testPhp = "$module->path/test/php";
|
$testPhp = "$module->path/test/php";
|
||||||
if (file_exists($testPhp)) {
|
if (file_exists($testPhp) && ! file_exists($module->path . '/phpunit.xml')) {
|
||||||
$unitModules->appendChild($phpunitXml->createElement('directory', $testPhp));
|
$unitModules->appendChild($phpunitXml->createElement('directory', $testPhp));
|
||||||
|
|
||||||
$testPhpRegression = "$testPhp/regression";
|
$testPhpRegression = "$testPhp/regression";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user