Merge pull request #59486 from soltysh/integration_fixes

Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Return information about which int tests failed in the summary

**What this PR does / why we need it**:
Currently if integration tests fail they will print the name of the failing tests as it goes, but the summary only tells that it failed. You need to know what to look for to be able to find all these occurrences. This PR provides a summary next to the failure information, eg:
```
FAILED TESTS: run_cluster_management_tests, run_plugins_tests, 
```
Which should greatly simplify developers integration debugging. 

**Release note**:
```release-note
NONE
```
pull/6/head
Kubernetes Submit Queue 2018-02-20 08:16:42 -08:00 committed by GitHub
commit c7414323d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 4 deletions

View File

@ -106,7 +106,7 @@ function record_command() {
juLog -output="${output}" -class="test-cmd" -name="${name}" "$@"
if [[ $? -ne 0 ]]; then
echo "Error when running ${name}"
foundError="True"
foundError="${foundError}""${name}"", "
fi
set -o nounset
@ -4609,7 +4609,7 @@ run_impersonation_tests() {
# Requires an env var SUPPORTED_RESOURCES which is a comma separated list of
# resources for which tests should be run.
runTests() {
foundError="False"
foundError=""
if [ -z "${SUPPORTED_RESOURCES:-}" ]; then
echo "Need to set SUPPORTED_RESOURCES env var. It is a list of resources that are supported and hence should be tested. Set it to (*) to test all resources"
@ -5108,8 +5108,8 @@ runTests() {
kube::test::clear_all
if [ "$foundError" == "True" ]; then
echo "TEST FAILED"
if [ ! -z "${foundError}" ]; then
echo "FAILED TESTS: ""${foundError}"
exit 1
fi
}