17 private $deploymentConfig;
42 private $moduleRegistryUninstaller;
46 $this->deploymentConfig = $this->createMock(\
Magento\Framework\
App\DeploymentConfig::class);
51 $dataSetupFactory->expects($this->any())->method(
'create')->willReturn($this->dataSetup);
52 $this->
output = $this->createMock(\Symfony\Component\Console\Output\OutputInterface::class);
55 $this->deploymentConfig,
63 $this->
output->expects($this->atLeastOnce())->method(
'writeln');
64 $this->dataSetup->expects($this->atLeastOnce())->method(
'deleteTableRow');
65 $this->moduleRegistryUninstaller->removeModulesFromDb($this->
output, [
'moduleA',
'moduleB']);
70 $this->
output->expects($this->atLeastOnce())->method(
'writeln');
71 $this->deploymentConfig->expects($this->once())
72 ->method(
'getConfigData')
73 ->willReturn([
'moduleA' => 1,
'moduleB' => 1,
'moduleC' => 1,
'moduleD' => 1]);
74 $this->loader->expects($this->once())->method(
'load')->willReturn([
'moduleC' => [],
'moduleD' => []]);
75 $this->writer->expects($this->once())
76 ->method(
'saveConfig')
84 $this->moduleRegistryUninstaller->removeModulesFromDeploymentConfig($this->
output, [
'moduleA',
'moduleB']);
output($string, $level=INFO, $label='')
testRemoveModulesFromDeploymentConfig()
testRemoveModulesFromDb()