[master] b264be7 More coverage

Federico G. Schwindt fgsch at lodoss.net
Sat May 6 00:12:06 CEST 2017


commit b264be7b44b13d06ccf414e4ede1ee5028485396
Author: Federico G. Schwindt <fgsch at lodoss.net>
Date:   Fri May 5 10:15:12 2017 +0100

    More coverage

diff --git a/bin/varnishtest/tests/u00005.vtc b/bin/varnishtest/tests/u00005.vtc
index d80f197..cd87c93 100644
--- a/bin/varnishtest/tests/u00005.vtc
+++ b/bin/varnishtest/tests/u00005.vtc
@@ -22,10 +22,6 @@ shell -err "grep -q LCK.vbe.destroy ${p1_out}"
 process p2 {varnishstat -1 -n ${v1_name} -f ^*vbe.destroy \
 	-f *vbe* -f *mempool* | tr '[1-9]' '0'} -run
 
-shell "grep -q vbe ${p2_out}"
-shell "grep -q mempool ${p2_out}"
-shell -err "grep -q LCK.vbe.destroy ${p2_out}"
-
 shell "cmp -s ${p1_out} ${p2_out}"
 
 shell -expect "cache_hit" \
@@ -39,8 +35,12 @@ shell -expect "Copyright (c) 2006 Verdens Gang AS" \
 	"varnishstat -V"
 shell -err -expect "Usage: varnishstat <options>" \
 	"varnishstat extra"
+shell -err -expect "-t: Range error" \
+	"varnishstat -n /nonexistent -t -1"
+shell -err -expect "-t: Syntax error" \
+	"varnishstat -n /nonexistent -t foo"
 shell -err -expect "Cannot open /nonexistent/_.vsm" \
-	"varnishstat -n /nonexistent"
+	"varnishstat -n /nonexistent -t 1"
 shell -expect "MAIN.uptime" \
 	"varnishstat -n ${v1_name} -1"
 shell -expect "<type>MAIN</type>" \
diff --git a/bin/varnishtest/tests/u00006.vtc b/bin/varnishtest/tests/u00006.vtc
index 221138e..196514e 100644
--- a/bin/varnishtest/tests/u00006.vtc
+++ b/bin/varnishtest/tests/u00006.vtc
@@ -41,6 +41,8 @@ shell -err -expect {-X: Syntax error in "**"} \
 	{varnishlog -X "**:bar"}
 shell -err -expect "Cannot open output file (No such file or directory)" \
 	{varnishlog -w /nonexistent/file}
+shell -err -expect "Only one of -n, -N and -r options may be used" \
+	{varnishlog -n ${v1_name} -N ${v1_name}/_.vsm}
 
 process p1 -wait
 shell {grep -q "0 CLI" ${tmpdir}/vlog}



More information about the varnish-commit mailing list