Skip to content

Commit 067468e

Browse files
committed
hack/test-templates.sh: Drop step executing test-port-forwarding.pl with nc
Signed-off-by: Norio Nomura <norio.nomura@gmail.com>
1 parent a45d888 commit 067468e

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

hack/test-templates.sh

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ if [[ -n ${CHECKS["container-engine"]} ]]; then
433433
fi
434434

435435
if [[ -n ${CHECKS["port-forwards"]} ]]; then
436-
PORT_FORWARDING_CONNECTION_TIMEOUT=3
436+
PORT_FORWARDING_CONNECTION_TIMEOUT=1
437437
INFO "Testing port forwarding rules using netcat and socat with connection timeout ${PORT_FORWARDING_CONNECTION_TIMEOUT}s"
438438
set -x
439439
if [[ ${NAME} == "alpine"* ]]; then
@@ -454,17 +454,10 @@ if [[ -n ${CHECKS["port-forwards"]} ]]; then
454454
if limactl shell "${NAME}" command -v dnf; then
455455
limactl shell "${NAME}" sudo dnf install -y nc socat
456456
fi
457-
if "${scriptdir}/test-port-forwarding.pl" "${NAME}" $PORT_FORWARDING_CONNECTION_TIMEOUT; then
458-
if "${scriptdir}/test-port-forwarding.pl" "${NAME}" socat $PORT_FORWARDING_CONNECTION_TIMEOUT; then
459-
INFO "Port forwarding rules work"
460-
else
461-
ERROR "Port forwarding rules do not work with socat"
462-
diagnose "$NAME"
463-
exit 1
464-
fi
457+
if "${scriptdir}/test-port-forwarding.pl" "${NAME}" socat $PORT_FORWARDING_CONNECTION_TIMEOUT; then
458+
INFO "Port forwarding rules work"
465459
else
466-
"${scriptdir}/test-port-forwarding.pl" "${NAME}" socat $PORT_FORWARDING_CONNECTION_TIMEOUT
467-
ERROR "Port forwarding rules do not work"
460+
ERROR "Port forwarding rules do not work with socat"
468461
diagnose "$NAME"
469462
exit 1
470463
fi

0 commit comments

Comments
 (0)