Skip to contentSkip to conversation

tests: shell: fix typo in vmap_timeout test script

PATCH Applied Gyorgy Sarvari 2 participants 2 messages Oct 26, 2025 netfilter

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tests: shell: fix typo in vmap_timeout test script

While executing the test suite from tests/shell folder, the following error is displayed many times:

tests/shell/testcases/maps/vmap_timeout: line 48: [: : integer expected

Looking at the script, a non-existing variable (expires) is tested instead of the existing one (expire).

This change corrects this.

Reproduction:
NFTABLESLIB=/usr/lib/nftables
tests/shell/run-tests.sh -v

---
 tests/shell/testcases/maps/vmap_timeout | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/shell/testcases/maps/vmap_timeout +1 -1
index 8ac7e8e7..55d1c1b9 100755
@@ -45,7 +45,7 @@ for i in $(seq 1 100) ; do
 		expire=$((RANDOM%utimeout))
 
 		expire_str=""
-		if [ "$expires" -gt 0 ]; then
+		if [ "$expire" -gt 0 ]; then
 			expire_str="expires ${expire}s"
 		fi
 
maintainer Applied
#1 lore raw
Quoted 4 lines · Gyorgy Sarvari

While executing the test suite from tests/shell folder, the following error is displayed many times:

tests/shell/testcases/maps/vmap_timeout: line 48: [: : integer expected

Applied, thank you.