make test: fix support for PARALLEL

There was an env variable PARALLEL and a -p command line flag,
but the value then wasn't passed on to "go test".

The new default is to not set any explicit parallelism, which
matches the prior (accidental?) behavior of ignoring PARALLEL.
This commit is contained in:
Patrick Ohly 2025-12-29 18:28:59 +01:00
parent 3226fe520d
commit 817e8cd898

View file

@ -101,7 +101,7 @@ isnum() {
[[ "$1" =~ ^[0-9]+$ ]]
}
PARALLEL="${PARALLEL:-1}"
PARALLEL="${PARALLEL:--1}"
while getopts "hp:i:" opt ; do
case ${opt} in
h)
@ -175,6 +175,10 @@ if [[ -n "${KUBE_RACE}" ]] ; then
goflags+=("${KUBE_RACE}")
fi
if [[ "${PARALLEL}" -gt 0 ]]; then
goflags+=(-p "${PARALLEL}")
fi
junitFilenamePrefix() {
if [[ -z "${KUBE_JUNIT_REPORT_DIR}" ]]; then
echo ""