Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
4c1b0345
Commit
4c1b0345
authored
Apr 24, 2020
by
Martin Blix Grydeland
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a test case
parent
c7799008
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
73 additions
and
0 deletions
+73
-0
r03301.vtc
bin/varnishtest/tests/r03301.vtc
+73
-0
No files found.
bin/varnishtest/tests/r03301.vtc
0 → 100644
View file @
4c1b0345
varnishtest "Issue 3301: Illegal error codes"
varnish v1 -vcl {
backend default none;
sub vcl_recv {
if (req.url == "/test1") {
return (synth(1301));
}
if (req.url == "/test2") {
return (synth(1001));
}
}
sub vcl_backend_fetch {
if (bereq.url == "/test3") {
return (error(1302));
}
if (bereq.url == "/test4") {
return (error(1000));
}
}
} -start
varnish v1 -cliok "param.set feature +http2"
client c1 {
stream 1 {
txreq -url /test1
rxresp
expect resp.status == 301
} -run
stream 3 {
txreq -url /test2
rxresp
expect resp.status == 503
} -run
stream 5 {
txreq -url /test3
rxresp
expect resp.status == 302
} -run
stream 7 {
txreq -url /test4
rxresp
expect resp.status == 503
} -run
} -run
client c2 {
txreq -url /test1
rxresp
expect resp.status == 301
expect resp.reason == "Moved Permanently"
txreq -url /test2
rxresp
expect resp.status == 503
} -run
client c2 {
txreq -url /test3
rxresp
expect resp.status == 302
expect resp.reason == "Found"
} -run
client c2 {
txreq -url /test4
rxresp
expect resp.status == 503
} -run
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment