Close cleanup; only try to run power actions against non-suspended & installed servers; closes #2760
This commit is contained in:
parent
26d409c29c
commit
16f49f8dc1
5 changed files with 40 additions and 107 deletions
|
@ -53,7 +53,7 @@ class BulkPowerActionCommandTest extends CommandTestCase
|
|||
$this->repository->expects('getServersForPowerAction')->with([], [])->andReturn($servers);
|
||||
|
||||
for ($i = 0; $i < count($servers); $i++) {
|
||||
$this->powerRepository->expects('setNode->setServer->send')->with('kill')->andReturnNull();
|
||||
$this->powerRepository->expects('setServer->send')->with('kill')->andReturnNull();
|
||||
}
|
||||
|
||||
$display = $this->runCommand($this->getCommand(), ['action' => 'kill'], ['yes']);
|
||||
|
@ -107,7 +107,7 @@ class BulkPowerActionCommandTest extends CommandTestCase
|
|||
->andReturn(1);
|
||||
|
||||
$this->repository->expects('getServersForPowerAction')->with([], [])->andReturn(Collection::make([$server]));
|
||||
$this->powerRepository->expects('setNode->setServer->send')->with('kill')->andReturnNull();
|
||||
$this->powerRepository->expects('setServer->send')->with('kill')->andReturnNull();
|
||||
|
||||
$display = $this->runCommand($this->getCommand(), [
|
||||
'action' => 'kill',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue