Skip to content

Commit

Permalink
Fix overlong junit filename prefixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivan Shvedunov committed Aug 18, 2016
1 parent 6659d80 commit 98ea7b9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion hack/make-rules/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -156,8 +156,10 @@ junitFilenamePrefix() {
fi
mkdir -p "${KUBE_JUNIT_REPORT_DIR}"
local KUBE_TEST_API_NO_SLASH="${KUBE_TEST_API//\//-}"
# This file name isn't parsed by anything, and tee needs a shorter file name.
# This filename isn't parsed by anything,
# and we must avoid exceeding 255 character filename limit.
KUBE_TEST_API_NO_SLASH="${KUBE_TEST_API_NO_SLASH//k8s.io-/}"
KUBE_TEST_API_NO_SLASH="$(echo "$KUBE_TEST_API_NO_SLASH"|sed 's/\([0-9]\)alpha\([0-9]\)/\1a\2/g;s/\([0-9]\)beta\([0-9]\)/\1b\2/g')"
echo "${KUBE_JUNIT_REPORT_DIR}/junit_${KUBE_TEST_API_NO_SLASH}_$(kube::util::sortable_date)"
}

Expand Down

0 comments on commit 98ea7b9

Please sign in to comment.