We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 864071f commit 07cf173Copy full SHA for 07cf173
server/src/test/java/com/cloud/hypervisor/KVMGuruTest.java
@@ -141,10 +141,12 @@ public void testSetVmQuotaPercentage() {
141
Mockito.verify(vmTO).setCpuQuotaPercentage(Mockito.anyDouble());
142
}
143
144
- @Test(expected = CloudRuntimeException.class)
+ @Test
145
public void testSetVmQuotaPercentageNullHost() {
146
Mockito.when(hostDao.findById(hostId)).thenReturn(null);
147
+ Mockito.when(vm.getLastHostId()).thenReturn(null);
148
guru.setVmQuotaPercentage(vmTO, vmProfile);
149
+ Mockito.verify(vmTO, Mockito.never()).setCpuQuotaPercentage(Mockito.anyDouble());
150
151
152
@Test
0 commit comments