Move run k8s conformance tests to k8s manager.
* Moved step with run k8s conformance tests from template
to k8s manager.
* Added possibility to change k8s conformance image.
* Bumped k8s image version from 1.6.2 to 1.6.4.
* Bumped k8s conformance image version from 1.6.2 to 1.6.4.
* Added possibility to skip conformance tests.
Change-Id: I6e4a3019f8fa6453005fc62614588209114cb02b
Reviewed-on: https://review.gerrithub.io/366656
Reviewed-by: Dennis Dmitriev <dis.xcom@gmail.com>
Reviewed-by: <apanchenko@mirantis.com>
Tested-by: Dennis Dmitriev <dis.xcom@gmail.com>
diff --git a/tcp_tests/managers/k8smanager.py b/tcp_tests/managers/k8smanager.py
index f16be6e..45cb078 100644
--- a/tcp_tests/managers/k8smanager.py
+++ b/tcp_tests/managers/k8smanager.py
@@ -280,3 +280,13 @@
pods = [pod.status.container_statuses[0].restart_count
for pod in self.get_running_pods(pod_name, namespace)]
return sum(pods)
+
+ def run_conformance(self, timeout=60 * 60):
+ with self.__underlay.remote(
+ host=self.__config.k8s.kube_host) as remote:
+ result = remote.check_call(
+ "docker run --rm --net=host -e API_SERVER="
+ "'http://127.0.0.1:8080' {}".format(
+ self.__config.k8s.k8s_conformance_image),
+ timeout=timeout)['stdout']
+ return result