Re-enable test-cmd.sh tests

This commit is contained in:
Jordan Liggitt
2017-01-25 11:23:19 -05:00
parent 90b5d4cbd8
commit d47f898500
3 changed files with 16 additions and 15 deletions

View File

@@ -22,6 +22,8 @@ set -o nounset
set -o pipefail
KUBE_ROOT=$(dirname "${BASH_SOURCE}")/../..
source "${KUBE_ROOT}/hack/lib/init.sh"
source "${KUBE_ROOT}/hack/lib/test.sh"
source "${KUBE_ROOT}/hack/make-rules/test-cmd-util.sh"
function run_kube_apiserver() {
@@ -135,10 +137,8 @@ run_kube_controller_manager
run_kubelet
create_node
SUPPORTED_RESOURCES=("*")
output_message=$(runTests "SUPPORTED_RESOURCES=${SUPPORTED_RESOURCES[@]}")
# Ensure that tests were run. We cannot check all resources here. We check a few
# to catch bugs due to which no tests run.
kube::test::if_has_string "${output_message}" "Testing kubectl(v1:pods)"
kube::test::if_has_string "${output_message}" "Testing kubectl(v1:services)"
# WARNING: Do not wrap this call in a subshell to capture output, e.g. output=$(runTests)
# Doing so will suppress errexit behavior inside runTests
runTests
kube::log::status "TESTS PASSED"