aboutsummaryrefslogtreecommitdiffstats
path: root/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch
diff options
context:
space:
mode:
Diffstat (limited to 'testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch')
-rw-r--r--testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch86
1 files changed, 24 insertions, 62 deletions
diff --git a/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch b/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch
index 30d4fdbf2e..efc153817f 100644
--- a/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch
+++ b/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch
@@ -1,67 +1,29 @@
-From 40fda813b0c33faa060f44dd2b078b8a8674b793 Mon Sep 17 00:00:00 2001
-From: Jan Chaloupka <jchaloup@redhat.com>
-Date: Mon, 14 Nov 2016 12:02:27 +0100
-Subject: [PATCH] make test-cmd run over hyperkube based kubectl
-
----
- src/k8s.io/kubernetes/hack/lib/test.sh | 3 ++-
- src/k8s.io/kubernetes/hack/make-rules/test-cmd.sh | 14 +-------------
- 2 files changed, 3 insertions(+), 14 deletions(-)
-
diff --git a/hack/lib/test.sh b/hack/lib/test.sh
-index 00f7ceb..26d9d85 100644
+index 575664a..7318cf9 100644
--- a/hack/lib/test.sh
+++ b/hack/lib/test.sh
-@@ -33,8 +33,9 @@ kube::test::get_object_assert() {
- local request=$2
- local expected=$3
- local args=${4:-}
+@@ -73,10 +73,10 @@ kube::test::object_assert() {
+ local object=$2
+ local request=$3
+ local expected=$4
+- local args=${5:-}
+ local get_args=${5:-}
-- res=$(eval kubectl ${args} get "${kube_flags[@]}" $object -o go-template=\"$request\")
-+ res=$(eval kubectl ${args} get "${kube_flags[@]}" ${get_args} $object -o go-template=\"$request\")
-
- if [[ "$res" =~ ^$expected$ ]]; then
- echo -n ${green}
-diff --git a/hack/make-rules/test-cmd.sh b/hack/make-rules/test-cmd.sh
-index e77b06d..b1cc52e 100755
---- a/hack/make-rules/test-cmd.sh
-+++ b/hack/make-rules/test-cmd.sh
-@@ -147,13 +147,6 @@ function wait-for-pods-with-label()
- kube::util::trap_add cleanup EXIT SIGINT
- kube::util::ensure-temp-dir
-
--BINS=(
-- cmd/kubectl
-- cmd/kube-apiserver
-- cmd/kube-controller-manager
--)
--make -C "${KUBE_ROOT}" WHAT="${BINS[*]}"
--
- kube::etcd::start
-
- ETCD_HOST=${ETCD_HOST:-127.0.0.1}
-@@ -190,11 +183,6 @@ kube::log::status "Running kubectl with no options"
- # Only run kubelet on platforms it supports
- if [[ "$(go env GOHOSTOS)" == "linux" ]]; then
-
--BINS=(
-- cmd/kubelet
--)
--make -C "${KUBE_ROOT}" WHAT="${BINS[*]}"
--
- kube::log::status "Starting kubelet in masterless mode"
- "${KUBE_OUTPUT_HOSTBIN}/kubelet" \
- --really-crash-for-testing=true \
-@@ -456,7 +444,7 @@ runTests() {
- # Describe command should print events information when show-events=true
- kube::test::describe_resource_events_assert pods true
- ### Validate Export ###
-- kube::test::get_object_assert 'pods/valid-pod' "{{.metadata.namespace}} {{.metadata.name}}" '<no value> valid-pod' "--export=true"
-+ kube::test::get_object_assert 'pods/valid-pod' "{{.metadata.namespace}} {{.metadata.name}}" '<no value> valid-pod' "" "--export=true"
-
- ### Dump current valid-pod POD
- output_pod=$(kubectl get pod valid-pod -o yaml --output-version=v1 "${kube_flags[@]}")
---
-1.9.3
-
+ for j in $(seq 1 ${tries}); do
+- res=$(eval kubectl get -a "${kube_flags[@]}" ${args} $object -o go-template=\"$request\")
++ res=$(eval kubectl ${args} get "${kube_flags[@]}" ${get_args} $object -o go-template=\"$request\")
+ if [[ "$res" =~ ^$expected$ ]]; then
+ echo -n ${green}
+ echo "$(kube::test::get_caller 3): Successful get $object $request: $res"
+diff --git a/hack/make-rules/test-e2e-node.sh b/hack/make-rules/test-e2e-node.sh
+index 2a68768..54a8233 100755
+--- a/hack/make-rules/test-e2e-node.sh
++++ b/hack/make-rules/test-e2e-node.sh
+@@ -168,6 +168,6 @@ else
+ --container-runtime-endpoint=${container_runtime_endpoint} \
+ --image-service-endpoint=${image_service_endpoint} \
+ --alsologtostderr --v 4 --report-dir=${artifacts} --node-name $(hostname) \
+- $test_args --k8s-bin-dir /usr/bin" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt"
++ $test_args" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt"
+ exit $?
+ fi