fix: keep NODE_EXTRA_CA_CERTS in test.sh

Network tests failed with self-signed certificate errors behind proxies that
inspect HTTPS (corporate proxies, sandboxes like Gondolin), because test.sh
starts tests with an empty environment.
This commit is contained in:
David Brailovsky 2026-10-13 11:23:56 +02:00
parent 7d75a0e3eb
commit e6220e1316

View file

@ -69,6 +69,11 @@ for name in SystemRoot SYSTEMROOT WINDIR COMSPEC PATHEXT; do
[[ -z "$value" ]] || test_env+=("$name=$value")
done
# Trust extra certificates of proxies that inspect HTTPS (corporate proxies, sandboxes).
# Network tests fail with self-signed certificate errors without it.
value="${NODE_EXTRA_CA_CERTS-}"
[[ -z "$value" ]] || test_env+=("NODE_EXTRA_CA_CERTS=$value")
# Preserve CI detection only for runner behavior and test reporting.
for name in CI GITHUB_ACTIONS; do
value="${!name-}"