mirror of
https://github.com/apache/cloudstack
synced 2026-08-02 05:26:35 +00:00
removed shutdown testcase (maybe, calling System.exit)
This commit is contained in:
parent
515e996292
commit
e14b071715
@ -288,19 +288,6 @@ public class ManagementServerMaintenanceManagerImplTest {
|
||||
});
|
||||
}
|
||||
|
||||
@Test
|
||||
public void triggerShutdownCmd() {
|
||||
ManagementServerHostVO msHost = mock(ManagementServerHostVO.class);
|
||||
Mockito.when(msHost.getState()).thenReturn(ManagementServerHost.State.ReadyToShutDown);
|
||||
Mockito.when(msHostDao.findById(1L)).thenReturn(msHost);
|
||||
TriggerShutdownCmd cmd = mock(TriggerShutdownCmd.class);
|
||||
Mockito.when(cmd.getManagementServerId()).thenReturn(1L);
|
||||
Mockito.when(clusterManagerMock.execute(anyString(), anyLong(), anyString(), anyBoolean())).thenReturn("Success");
|
||||
|
||||
spy.triggerShutdown(cmd);
|
||||
Mockito.verify(clusterManagerMock, Mockito.times(1)).execute(anyString(), anyLong(), anyString(), anyBoolean());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void prepareForMaintenanceAndCancelFromMaintenanceState() {
|
||||
Mockito.doNothing().when(jobManagerMock).disableAsyncJobs();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user