mirror of
https://github.com/Combodo/iTop.git
synced 2026-08-04 12:58:24 +02:00
N°9827 - Unable to launch check compatibility when a module with bad dependencies is in production-modules (#978)
* N°9827 - Unable to launch check compatibility when a module with bad dependencies is in production-modules * Update unit tests * N°9827 - Unable to launch check compatibility when a module with bad dependencies is in production-modules
This commit is contained in:
@@ -394,7 +394,7 @@ class WizStepModulesChoiceTest extends ItopTestCase
|
||||
'mandatory' => false,
|
||||
],
|
||||
],
|
||||
'A non installed extension with missing dependencies should be not checked and disabled' => [
|
||||
'A non installed and non mandatory extension with missing dependencies and without force uninstall should be not checked and disabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => false,
|
||||
@@ -421,7 +421,7 @@ class WizStepModulesChoiceTest extends ItopTestCase
|
||||
'mandatory' => false,
|
||||
],
|
||||
],
|
||||
'An installed extension with missing dependencies should be not checked and disabled' => [
|
||||
'An installed non mandatory extension with missing dependencies and without force uninstall should be not checked and disabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => true,
|
||||
@@ -448,6 +448,114 @@ class WizStepModulesChoiceTest extends ItopTestCase
|
||||
'mandatory' => false,
|
||||
],
|
||||
],
|
||||
'A non installed and non mandatory extension with missing dependencies and force uninstall should be not checked and enabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => false,
|
||||
'missing_dependencies' => [
|
||||
'itop-ext1-1',
|
||||
],
|
||||
],
|
||||
],
|
||||
'aWizardStepDefinition' => [
|
||||
'extension_code' => 'itop-ext1',
|
||||
'mandatory' => false,
|
||||
'uninstallable' => true,
|
||||
'missing_dependencies' => true,
|
||||
],
|
||||
'bCurrentSelected' => false,
|
||||
'bDisableUninstallChecks' => true,
|
||||
'aExpectedFlags' => [
|
||||
'uninstallable' => true,
|
||||
'missing' => false,
|
||||
'installed' => false,
|
||||
'disabled' => false,
|
||||
'checked' => false,
|
||||
'dependency_issue' => true,
|
||||
'mandatory' => false,
|
||||
],
|
||||
],
|
||||
'An installed non mandatory extension with missing dependencies and force uninstall should be not checked and enabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => true,
|
||||
'missing_dependencies' => [
|
||||
'itop-ext1-1',
|
||||
],
|
||||
],
|
||||
],
|
||||
'aWizardStepDefinition' => [
|
||||
'extension_code' => 'itop-ext1',
|
||||
'mandatory' => false,
|
||||
'uninstallable' => true,
|
||||
'missing_dependencies' => true,
|
||||
],
|
||||
'bCurrentSelected' => false,
|
||||
'bDisableUninstallChecks' => true,
|
||||
'aExpectedFlags' => [
|
||||
'uninstallable' => true,
|
||||
'missing' => false,
|
||||
'installed' => true,
|
||||
'disabled' => false,
|
||||
'checked' => false,
|
||||
'dependency_issue' => true,
|
||||
'mandatory' => false,
|
||||
],
|
||||
],
|
||||
'An installed mandatory extension with missing dependencies and without force uninstall should be checked and disabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => true,
|
||||
'missing_dependencies' => [
|
||||
'itop-ext1-1',
|
||||
],
|
||||
],
|
||||
],
|
||||
'aWizardStepDefinition' => [
|
||||
'extension_code' => 'itop-ext1',
|
||||
'mandatory' => true,
|
||||
'uninstallable' => true,
|
||||
'missing_dependencies' => true,
|
||||
],
|
||||
'bCurrentSelected' => false,
|
||||
'bDisableUninstallChecks' => true,
|
||||
'aExpectedFlags' => [
|
||||
'uninstallable' => true,
|
||||
'missing' => false,
|
||||
'installed' => true,
|
||||
'disabled' => true,
|
||||
'checked' => true,
|
||||
'dependency_issue' => true,
|
||||
'mandatory' => true,
|
||||
],
|
||||
],
|
||||
'An non installed mandatory extension with missing dependencies and without force uninstall should be checked and disabled' => [
|
||||
'aExtensionsOnDiskOrDb' => [
|
||||
'itop-ext1' => [
|
||||
'installed' => false,
|
||||
'missing_dependencies' => [
|
||||
'itop-ext1-1',
|
||||
],
|
||||
],
|
||||
],
|
||||
'aWizardStepDefinition' => [
|
||||
'extension_code' => 'itop-ext1',
|
||||
'mandatory' => true,
|
||||
'uninstallable' => true,
|
||||
'missing_dependencies' => true,
|
||||
],
|
||||
'bCurrentSelected' => false,
|
||||
'bDisableUninstallChecks' => true,
|
||||
'aExpectedFlags' => [
|
||||
'uninstallable' => true,
|
||||
'missing' => false,
|
||||
'installed' => false,
|
||||
'disabled' => true,
|
||||
'checked' => true,
|
||||
'dependency_issue' => true,
|
||||
'mandatory' => true,
|
||||
],
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user