List<Endpoint> endpoints() {
        try {
            String urlString = String.format("%s/api/v1/namespaces/%s/pods", kubernetesMaster, namespace);
            return enrichWithPublicAddresses(parsePodsList(callGet(urlString)));
        } catch (RestClientException e) {
            return handleKnownException(e);
        }
    }
@Test(expected = KubernetesClientException.class)
    public void endpointsFailFastWhenNoPublicAccess() throws JsonProcessingException {
        // given
        cleanUpClient();
        kubernetesClient = newKubernetesClient(ExposeExternallyMode.ENABLED, false, null, null);

        stub(String.format("/api/v1/namespaces/%s/pods", NAMESPACE), podsListResponse());
        stub(String.format("/api/v1/namespaces/%s/endpoints", NAMESPACE), endpointsListResponse());

        stub(String.format("/api/v1/namespaces/%s/services/service-0", NAMESPACE),
                service(servicePort(0, 0, 0), servicePort(1, 1, 2)));
        stub(String.format("/api/v1/namespaces/%s/services/hazelcast-0", NAMESPACE),
                service(servicePort(0, 0, 0), servicePort(1, 1, 2)));
        stub(String.format("/api/v1/namespaces/%s/services/service-1", NAMESPACE),
                service(servicePort(0, 0, 0), servicePort(1, 1, 2)));
        stub("/api/v1/nodes/node-name-1", node("node-name-1", "10.240.0.21", "35.232.226.200"));
        stub("/api/v1/nodes/node-name-2", node("node-name-2", "10.240.0.22", "35.232.226.201"));

        // when
        List<Endpoint> result = kubernetesClient.endpoints();

        // then
        // exception
    }