[master] 1adbf27d7 Check obj.uncacheable

Poul-Henning Kamp phk at FreeBSD.org
Mon May 17 11:31:05 UTC 2021


commit 1adbf27d7ae73e02509010eefb5ddff9abb6d697
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Mon May 17 11:23:21 2021 +0000

    Check obj.uncacheable

diff --git a/bin/varnishtest/tests/b00002.vtc b/bin/varnishtest/tests/b00002.vtc
index 2c978ee54..ade1169d3 100644
--- a/bin/varnishtest/tests/b00002.vtc
+++ b/bin/varnishtest/tests/b00002.vtc
@@ -13,6 +13,9 @@ varnish v1 -arg "-sTransient=default,1m" -vcl+backend {
 	sub vcl_backend_response {
 		set beresp.http.x-ttl = beresp.ttl;
 	}
+	sub vcl_deliver {
+		set resp.http.o_uncacheable = obj.uncacheable;
+	}
 } -start
 
 # check that there are no TTL LogTags between the
@@ -32,11 +35,9 @@ client c1 {
 	expect resp.status == 200
 	expect resp.http.connection == close
 	expect resp.http.x-ttl == 0.000
+	expect resp.http.o_uncacheable == true
 } -run
 
-# Give varnish a chance to update stats
-delay .1
-
 varnish v1 -expect n_object == 0
 varnish v1 -expect SM?.Transient.g_alloc == 0
 varnish v1 -expect sess_conn == 1


More information about the varnish-commit mailing list