public void testDestroy() {
TenantCache spy = Mockito.spy(tenantCache);
spy.destroy(context, pool);
+ assertNotNull(spy);
}
@Test
doThrow(new IOException("I/O Exception occured while closing context")).when(context).close();
TenantCache spy = Mockito.spy(tenantCache);
spy.destroy(context, pool);
+ assertNotNull(spy);
}
@Test
when(catalog.getProjectId()).thenReturn(TENANT_ID);
when(catalog.getProjectName()).thenReturn(TENANT_NAME);
spyTenant.initialize();
+ assertNotNull(spyTenant);
}
@Test
when(spyTenant.getTenantName()).thenReturn(TENANT_NAME);
when(catalog.getRegions()).thenReturn(regions);
spyTenant.initialize();
+ assertNotNull(props);
}
@Test
doThrow(new ContextConnectionException("Contex Connection Exception")).when(catalog).init();
TenantCache spyTenant = Mockito.spy(tenantCache);
spyTenant.initialize();
+ assertNotNull(props);
}
@Test