mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-9564: Fix NPE due to intermittent test assertion
The test assertion on a pool object may return a null object, as objects can be randomly expired/tombstoned. This will fix a NPE sometimes seen due to recently merge for the fix for CLOUDSTACK-9564. Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This commit is contained in:
parent
48b28f7d6e
commit
dcbf3c8689
|
|
@ -114,7 +114,5 @@ public class VmwareContextPoolTest {
|
|||
totalRegistrations += client.count();
|
||||
}
|
||||
Mockito.verify(vmwareContextPool, Mockito.atLeast(totalRegistrations)).registerContext(Mockito.any(VmwareContext.class));
|
||||
Assert.assertEquals(vmwareContextPool.composePoolKey(vmwareAddress, vmwareUsername),
|
||||
vmwareContextPool.getContext(vmwareAddress, vmwareUsername).getPoolKey());
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue