All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: <netfilter-devel@vger.kernel.org>
Cc: Florian Westphal <fw@strlen.de>
Subject: [PATCH nft] tests: shell: fix spurious dump failure in vmap timeout test
Date: Fri, 11 Oct 2024 02:32:08 +0200	[thread overview]
Message-ID: <20241011003211.4780-1-fw@strlen.de> (raw)

Blamed commit can update the timeout to 6s, but last line waits
for 5 seconds and expects that to be enough to have all elements vanish.

Fix the typo to limit update timeout also to 5 seconds and not 6.
This fixes spurious dump failures like this one:

-               elements = { 1.2.3.4 . 22 : jump ssh_input }
+               elements = { 1.2.3.4 . 22 : jump ssh_input,
+                            10.0.95.144 . 38023 timeout 6s expires 545ms : jump other_input }

Fixes: db80037c0279 ("tests: shell: extend vmap test with updates")
Signed-off-by: Florian Westphal <fw@strlen.de>
---
 tests/shell/testcases/maps/vmap_timeout | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/shell/testcases/maps/vmap_timeout b/tests/shell/testcases/maps/vmap_timeout
index 3f0563afacac..6d73f3cc9ae2 100755
--- a/tests/shell/testcases/maps/vmap_timeout
+++ b/tests/shell/testcases/maps/vmap_timeout
@@ -32,7 +32,7 @@ for i in $(seq 1 100) ; do
 		timeout=$((timeout+1))
 		expire=$((RANDOM%timeout))
 		utimeout=$((RANDOM%5))
-		utimeout=$((timeout+1))
+		utimeout=$((utimeout+1))
 
 		timeout_str="timeout ${timeout}s"
 		expire_str=""
-- 
2.45.2


             reply	other threads:[~2024-10-11  1:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-11  0:32 Florian Westphal [this message]
2024-10-11  8:39 ` [PATCH nft] tests: shell: fix spurious dump failure in vmap timeout test Phil Sutter
2024-10-11  9:15   ` Florian Westphal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241011003211.4780-1-fw@strlen.de \
    --to=fw@strlen.de \
    --cc=netfilter-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.