vtest "Rearm timeout_idle upon HTTP/1 keep-alive"

barrier b1 cond 2
barrier b2 cond 2

vinyl v1 -cliok "param.set timeout_idle 1h"
vinyl v1 -vcl {
	backend be none;
	sub vcl_recv {
		set sess.timeout_idle = param.timeout_idle;
		return (synth(200));
	}
} -start

client c1 {
	txreq
	rxresp
	expect resp.status == 200

	barrier b1 sync
	barrier b2 sync

	txreq
	rxresp
	expect resp.status == 200

	expect_close
} -start

barrier b1 sync
vinyl v1 -cliok "param.set timeout_idle 1ms"
barrier b2 sync

client c1 -wait
