PodService { public List<HostPodVO> getAllPodsEnabledFromZone(long zoneId) { return hostPodDao.listByDataCenterId(zoneId); }  List<HostPodVO> getAllPodsEnabledFromZone(long zoneId); HostPodVO findPodById(Long podId); boolean isThereAnyHostOnPodDeactivatedByOurManager(long id);  }
@Test public void getAllPodsEnabledFromZoneTest() { List<HostPodVO> hosts = new ArrayList<>(); Mockito.doReturn(hosts).when(hostPodDao).listByDataCenterId(Mockito.anyLong()); List<HostPodVO> result = spy.getAllPodsEnabledFromZone(0l); Mockito.verify(hostPodDao).listByDataCenterId(Mockito.anyLong()); Assert.assertEquals(hosts, result); }