aboutsummaryrefslogblamecommitdiffstats
path: root/testing/kubernetes/make-test-cmd-run-over-hyperkube-based-kubectl.patch
blob: 16f4407e2238e79cc8a7c42f4e68a6c4abe1547a (plain) (tree)
1
2
3
4
5
6
7
8
9

                                                

                      
                                                 



                    

                        




                                                                                                               


                                                                                        
diff --git a/hack/lib/test.sh b/hack/lib/test.sh
index 62a6765f..775d1d96 100644
--- a/hack/lib/test.sh
+++ b/hack/lib/test.sh
@@ -77,12 +77,12 @@ kube::test::object_assert() {
   local object=$2
   local request=$3
   local expected=$4
-  local args=${5:-}
+  local get_args=${5:-}
 
   for j in $(seq 1 "${tries}"); do
     # shellcheck disable=SC2086
     # Disabling because "args" needs to allow for expansion here
-    res=$(eval kubectl get "${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}"