summaryrefslogtreecommitdiff
path: root/regress/usr.sbin/relayd/args-http-contentlength.pl
blob: fc36cd965561c99e789aa4e0c9ea3aa90c7c7e32 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# test persistent http 1.1 connection and grep for content length

use strict;
use warnings;

my @lengths = (1, 2, 0, 3, 4);
our %args = (
    client => {
	func => \&http_client,
	lengths => \@lengths,
    },
    relayd => {
	protocol => [ "http",
	    "request header log foo",
	    "response header log Content-Length",
	],
	loggrep => [ map { "log 'Content-Length: $_'" } @lengths ],
    },
    server => {
	func => \&http_server,
    },
    lengths => \@lengths,
);

1;