From ad4de2284dc47a88c1c73cc7bc55a745fec9eb13 Mon Sep 17 00:00:00 2001 From: Jozsef Kadlecsik Date: Fri, 14 Oct 2016 23:38:30 +0200 Subject: Correct tests to check the number of entries too Give enough time for the entries to timeout before listing, so that we get the correct number of entries. Signed-off-by: Jozsef Kadlecsik --- tests/comment.t | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/comment.t') diff --git a/tests/comment.t b/tests/comment.t index 204093a..130a033 100644 --- a/tests/comment.t +++ b/tests/comment.t @@ -117,7 +117,7 @@ # Hash comment: Destroy test set 0 ipset destroy test # Hash comment: create set with timeout -0 ipset create test hash:ip comment timeout 5 +0 ipset create test hash:ip comment timeout 4 # Hash comment: Add multiple elements with default timeout 0 for x in `seq 0 255`; do echo "add test 2.0.0.$x comment \\\"text message $x\\\""; done | ipset restore # Hash comment: Add multiple elements with zero timeout @@ -126,8 +126,8 @@ 0 ipset list test | grep -v Revision: | sed 's/timeout ./timeout x/' > .foo0 && ./sort.sh .foo0 # Hash comment: Check listing 0 diff -u -I 'Size in memory.*' .foo comment.t.list21 -# Sleep 6s so that entries can time out -0 sleep 6s +# Sleep 5s so that entries can time out +0 sleep 5s # Hash comment: List set 0 ipset list test | grep -v Revision: | sed 's/timeout ./timeout x/' > .foo0 && ./sort.sh .foo0 # Hash comment: Check listing -- cgit v1.2.3