vtest "r00979.vtc Test restart when do_stream in vcl_deliver"

server s1 {
	rxreq
	txresp -hdr "Connection: close" -gzipbody "1"

	expect_close
	accept
	rxreq
	txresp -body "11"
} -start

vinyl v1 -vcl+backend {
	sub vcl_backend_response {
		set beresp.do_stream = true;
		set beresp.uncacheable = true;
	}
	sub vcl_deliver {
		if (req.restarts == 0) {
			return (restart);
		}
	}
} -start

vinyl v1 -cliok "param.set debug +syncvsl"

client c1 {
	txreq
	rxresp
	expect resp.status == 200
	expect resp.bodylen == 2
} -run
