@Test void testGetPodOperationsForController() { String controllerUid = "some-uid"; Map<String, String> selectorLabels = Collections.singletonMap("foo", "bar"); FilterWatchListDeletable<Pod, PodList, Boolean, Watch> filterWatchListDeletable = getMockPodFilterOperation(controllerUid); when(podOperations.withLabels(any())).thenReturn(filterWatchListDeletable); List<PodResource<Pod, DoneablePod>> podResources = PodOperationUtil.getPodOperationsForController(podOperations, controllerUid, selectorLabels); assertNotNull(podResources); assertEquals(1, podResources.size()); }
public static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout) { return getPodOperationsForController(PodOperationUtil.getGenericPodOperations(context, isPretty, podLogWaitTimeout), controllerUid, selectorLabels); }
PodOperationUtil { public static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout) { return getPodOperationsForController(PodOperationUtil.getGenericPodOperations(context, isPretty, podLogWaitTimeout), controllerUid, selectorLabels); } }
PodOperationUtil { public static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout) { return getPodOperationsForController(PodOperationUtil.getGenericPodOperations(context, isPretty, podLogWaitTimeout), controllerUid, selectorLabels); } private  PodOperationUtil(); }
PodOperationUtil { public static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout) { return getPodOperationsForController(PodOperationUtil.getGenericPodOperations(context, isPretty, podLogWaitTimeout), controllerUid, selectorLabels); } private  PodOperationUtil(); static List<PodResource<Pod, DoneablePod>> getFilteredPodsForLogs(PodOperationsImpl podOperations, PodList controllerPodList, String controllerUid); static PodOperationsImpl getGenericPodOperations(OperationContext context, boolean isPretty, Integer podLogWaitTimeout); static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout); static void waitUntilReadyBeforeFetchingLogs(PodResource<Pod, DoneablePod> podOperation, Integer logWaitTimeout); }
PodOperationUtil { public static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout) { return getPodOperationsForController(PodOperationUtil.getGenericPodOperations(context, isPretty, podLogWaitTimeout), controllerUid, selectorLabels); } private  PodOperationUtil(); static List<PodResource<Pod, DoneablePod>> getFilteredPodsForLogs(PodOperationsImpl podOperations, PodList controllerPodList, String controllerUid); static PodOperationsImpl getGenericPodOperations(OperationContext context, boolean isPretty, Integer podLogWaitTimeout); static List<PodResource<Pod, DoneablePod>> getPodOperationsForController(OperationContext context, String controllerUid, Map<String, String> selectorLabels, boolean isPretty, Integer podLogWaitTimeout); static void waitUntilReadyBeforeFetchingLogs(PodResource<Pod, DoneablePod> podOperation, Integer logWaitTimeout);  }