com.codacy.scoobydoo.kubernetes.KubernetesWrapperSpy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scooby-doo-fwk Show documentation
Show all versions of scooby-doo-fwk Show documentation
Automated testing framework
package com.codacy.scoobydoo.kubernetes;
import io.fabric8.kubernetes.api.model.Pod;
import io.fabric8.kubernetes.client.KubernetesClient;
import io.fabric8.kubernetes.client.LocalPortForward;
import java.util.Map;
public class KubernetesWrapperSpy extends KubernetesWrapper {
private boolean firstRun;
public KubernetesWrapperSpy(KubernetesClient kubernetesClient) {
super(kubernetesClient);
this.firstRun = true;
}
public Map> getOpenPortForwards() {
return super.openPortForwards;
}
protected boolean testPortForwardCallback(LocalPortForward portForward) {
if (this.firstRun) {
this.firstRun = false;
return false;
} else {
return true;
}
}
}