From 83056457d6bf49510f6f2235b9f0a13875f11077 Mon Sep 17 00:00:00 2001 From: Dan Mihai Date: Fri, 26 Jul 2024 18:48:18 +0000 Subject: [PATCH] tests: k8s-policy-pod: avoid word splitting Avoid potential word splitting when using array of command args array. Signed-off-by: Dan Mihai --- tests/integration/kubernetes/k8s-policy-pod.bats | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/integration/kubernetes/k8s-policy-pod.bats b/tests/integration/kubernetes/k8s-policy-pod.bats index db01d3d2d2..57a2c4e3bc 100644 --- a/tests/integration/kubernetes/k8s-policy-pod.bats +++ b/tests/integration/kubernetes/k8s-policy-pod.bats @@ -64,7 +64,7 @@ wait_for_pod_ready() { @test "Able to read env variables sourced from configmap using envFrom" { wait_for_pod_ready - expected_env_var=$(kubectl exec "${pod_name}" -- ${exec_command[@]}) + expected_env_var=$(kubectl exec "${pod_name}" -- "${exec_command[@]}") [ "$expected_env_var" = "value-3" ] || fail "expected_env_var is not equal to value-3" }