mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-30 15:05:27 +00:00
Run ginkgo in foreground, elminiate wait & pgrep
Use bash process substitution for sending ginkgo output through tee, allowing easy capture of the ginkgo exit code and avoiding use of wait or pgrep. For #78699
This commit is contained in:
parent
ad899665ea
commit
2242718e17
@ -67,9 +67,8 @@ ginkgo_args+=(
|
||||
)
|
||||
|
||||
set -x
|
||||
/usr/local/bin/ginkgo "${ginkgo_args[@]}" /usr/local/bin/e2e.test -- --disable-log-dump --repo-root=/kubernetes --provider="${E2E_PROVIDER}" --report-dir="${RESULTS_DIR}" --kubeconfig="${KUBECONFIG}" -v="${E2E_VERBOSITY}" | tee "${RESULTS_DIR}"/e2e.log &
|
||||
/usr/local/bin/ginkgo "${ginkgo_args[@]}" /usr/local/bin/e2e.test -- --disable-log-dump --repo-root=/kubernetes --provider="${E2E_PROVIDER}" --report-dir="${RESULTS_DIR}" --kubeconfig="${KUBECONFIG}" -v="${E2E_VERBOSITY}" > >(tee "${RESULTS_DIR}"/e2e.log)
|
||||
ret=$?
|
||||
set +x
|
||||
# $! is the pid of tee, not ginkgo
|
||||
wait "$(pgrep ginkgo)" && ret=0 || ret=$?
|
||||
saveResults
|
||||
exit ${ret}
|
||||
|
Loading…
Reference in New Issue
Block a user