add group prefix matching for kubectl usage

This commit is contained in:
deads2k
2016-09-06 14:03:36 -04:00
parent dc529a03b1
commit f9b498e341
3 changed files with 156 additions and 1 deletions

View File

@@ -947,6 +947,9 @@ __EOF__
kube::test::if_has_string "${output_message}" 'extensions/v1beta1'
output_message=$(kubectl get hpa.autoscaling -o=jsonpath='{.items[0].apiVersion}' 2>&1 "${kube_flags[@]}")
kube::test::if_has_string "${output_message}" 'autoscaling/v1'
# tests kubectl group prefix matching
output_message=$(kubectl get hpa.autoscal -o=jsonpath='{.items[0].apiVersion}' 2>&1 "${kube_flags[@]}")
kube::test::if_has_string "${output_message}" 'autoscaling/v1'
# Clean up
# Note that we should delete hpa first, otherwise it may fight with the rc reaper.
kubectl delete hpa frontend "${kube_flags[@]}"