Skip to content

Commit

Permalink
Merge pull request #15227 from liggitt/osx-integration-fix
Browse files Browse the repository at this point in the history
Merged by openshift-bot
  • Loading branch information
OpenShift Bot authored Jul 18, 2017
2 parents 9ae8fce + 02cb731 commit 7d661a2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion hack/lib/util/misc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ function os::util::curl_etcd() {
-out "${etcd_client_cert_p12}" \
-password "pass:${etcd_client_cert_p12_password}"
fi
b

curl --fail --silent --cacert "${ca_bundle}" \
--cert "${etcd_client_cert_p12}:${etcd_client_cert_p12_password}" "${full_url}"
else
Expand Down
14 changes: 10 additions & 4 deletions hack/test-integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,13 +106,19 @@ loop="${TIMES:-1}"
# hack/test-integration.sh WatchBuilds
# hack/test-integration.sh Template*
# hack/test-integration.sh "(WatchBuilds|Template)"
tests=( $(go run "${OS_ROOT}/hack/listtests.go" -prefix="${OS_GO_PACKAGE}/${package}.Test" "${testexec}" | grep -E "${1-Test}") )
listTemplate='{{ range $i,$file := .TestGoFiles }}{{$.Dir}}/{{ $file }}{{ "\n" }}{{end}}'
tests=( $(go list -f "${listTemplate}" "./${package}" | xargs grep -E -o --no-filename '^func Test[^(]+' | cut -d ' ' -f 2 | grep -E "${1-Test}") )

if [[ "${#tests[@]}" == "0" ]]; then
os::text::print_red "No tests found matching \"${1-Test}\""
exit 1
fi

# run each test as its own process
ret=0
test_result="ok"
pushd "${OS_ROOT}/${package}" &>/dev/null
test_start_time=$(date +%s%3N)
test_start_time=$(date +%s)
for test in "${tests[@]}"; do
for((i=0;i<${loop};i+=1)); do
if ! (exectest "${test}" ${@:2}); then
Expand All @@ -121,10 +127,10 @@ for test in "${tests[@]}"; do
fi
done
done
test_end_time=$(date +%s%3N)
test_end_time=$(date +%s)
test_duration=$((test_end_time - test_start_time))

echo "${test_result} github.com/openshift/origin/test/integration $((test_duration / 1000)).$((test_duration % 1000))s" >> "${JUNIT_REPORT_OUTPUT:-/dev/null}"
echo "${test_result} github.com/openshift/origin/test/integration $((test_duration)).000s" >> "${JUNIT_REPORT_OUTPUT:-/dev/null}"

popd &>/dev/null

Expand Down

0 comments on commit 7d661a2

Please sign in to comment.