Tests that use the kubernetes mock should be configured to trust certificates.

This commit is contained in:
Ioannis Canellos
2016-04-27 19:58:18 +03:00
parent e89213c302
commit 715300e4b8
3 changed files with 9 additions and 3 deletions

View File

@@ -6,10 +6,13 @@ Spring Cloud integration with Kubernetes
### Features
- Auto configuration for the Kubernetes client
- Externalize configuration to ConfigMap
- DiscoveryClient implementation for Kubernetes
- Health Indicator for Pods
- Automatic activation of the "Kubernetes" profile when running inside Kubernetes.
- Ribbon discovery in Kubernetes.
- Automatic activation of the "Kubernetes" profile when running inside Kubernetes
- Ribbon discovery in Kubernetes
- Zipkin discovery in Kubernetes
- ConfigMap / Archaius Bridge
### Building
@@ -29,3 +32,4 @@ The project provides a "starter" module, so you just need to add the following d
<version>x.y.z</version>
</dependency>
## Configuring the

View File

@@ -33,6 +33,7 @@ import spock.lang.Specification
[
"spring.application.name=testapp",
"spring.cloud.kubernetes.client.namespace=testns",
"spring.cloud.kubernetes.client.trustCerts=true",
"spring.cloud.kubernetes.config.namespace=testns"
])
@EnableConfigurationProperties
@@ -79,9 +80,9 @@ class CoreTest extends Specification {
expect:
config.getMasterUrl().equals(mockClient.getConfiguration().getMasterUrl());
config.getNamespace().equals("testns");
config.trustCerts
}
def "Kubernetes client bean should be present"() {
expect:
client != null

View File

@@ -37,6 +37,7 @@ import spock.lang.Specification
[
"spring.application.name=testapp",
"spring.cloud.kubernetes.client.namespace=testns",
"spring.cloud.kubernetes.client.trustCerts=true",
"spring.cloud.kubernetes.config.namespace=testns"
])
@RibbonClient(name = "testapp", configuration = KubernetesRibbonClientConfiguration.class)