From 89d568d7d2e8bdf382f49217f8b39004610d801f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Benencia?= Date: Sun, 23 Jun 2024 10:47:08 -0700 Subject: [PATCH] test_e2e.sh: Quote literal { } Fixes SC1083. Part of #891. --- test_e2e.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test_e2e.sh b/test_e2e.sh index 938557e..5b6b40e 100755 --- a/test_e2e.sh +++ b/test_e2e.sh @@ -2524,23 +2524,23 @@ function e2e::expose_http() { done # check that health endpoint fails - if [[ $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 503 ]] ; then - fail "health endpoint should have failed: $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT)" + if [[ $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 503 ]] ; then + fail "health endpoint should have failed: $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT)" fi wait_for_sync "${MAXWAIT}" # check that health endpoint is alive - if [[ $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 200 ]] ; then + if [[ $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 200 ]] ; then fail "health endpoint failed" fi # check that the metrics endpoint exists - if [[ $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT/metrics) -ne 200 ]] ; then + if [[ $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT/metrics) -ne 200 ]] ; then fail "metrics endpoint failed" fi # check that the pprof endpoint exists - if [[ $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT/debug/pprof/) -ne 200 ]] ; then + if [[ $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT/debug/pprof/) -ne 200 ]] ; then fail "pprof endpoint failed" fi } @@ -2579,7 +2579,7 @@ function e2e::expose_http_after_restart() { sleep 2 # wait for first loop to confirm synced # check that health endpoint is alive - if [[ $(curl --write-out %{http_code} --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 200 ]] ; then + if [[ $(curl --write-out '%{http_code}' --silent --output /dev/null http://localhost:$HTTP_PORT) -ne 200 ]] ; then fail "health endpoint failed" fi assert_link_exists "$ROOT/link"