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
10e3b177
Commit
10e3b177
authored
Sep 10, 2021
by
Dridi Boukelmoune
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vtc: Move the remaining vmod_directors test cases
With a tiny bit of polish here and there.
parent
7cfe14da
Changes
17
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
28 additions
and
28 deletions
+28
-28
README
bin/varnishtest/tests/README
+3
-1
directors_b00007.vtc
vmod/tests/directors_b00007.vtc
+0
-0
directors_c00003.vtc
vmod/tests/directors_c00003.vtc
+13
-18
directors_c00004.vtc
vmod/tests/directors_c00004.vtc
+1
-1
directors_c00005.vtc
vmod/tests/directors_c00005.vtc
+9
-6
directors_c00006.vtc
vmod/tests/directors_c00006.vtc
+1
-1
directors_c00007.vtc
vmod/tests/directors_c00007.vtc
+0
-0
directors_c00008.vtc
vmod/tests/directors_c00008.vtc
+1
-1
directors_c00009.vtc
vmod/tests/directors_c00009.vtc
+0
-0
directors_c00010.vtc
vmod/tests/directors_c00010.vtc
+0
-0
directors_c00011.vtc
vmod/tests/directors_c00011.vtc
+0
-0
directors_c00012.vtc
vmod/tests/directors_c00012.vtc
+0
-0
directors_c00013.vtc
vmod/tests/directors_c00013.vtc
+0
-0
directors_c00014.vtc
vmod/tests/directors_c00014.vtc
+0
-0
directors_c00015.vtc
vmod/tests/directors_c00015.vtc
+0
-0
directors_s00000.vtc
vmod/tests/directors_s00000.vtc
+0
-0
directors_v00000.vtc
vmod/tests/directors_v00000.vtc
+0
-0
No files found.
bin/varnishtest/tests/README
View file @
10e3b177
...
...
@@ -17,7 +17,7 @@ Naming scheme
id ~ ^a02 --> HTTP2
id ~ ^b --> Basic functionality tests
id ~ ^c --> Complex functionality tests
id ~ ^d --> Director
VMOD
tests
id ~ ^d --> Director
facility
tests
id ~ ^e --> ESI tests
id ~ ^f --> Security related tests
id ~ ^g --> GZIP tests
...
...
@@ -34,3 +34,5 @@ Naming scheme
id ~ ^t02 --> HTTP2
id ~ ^u --> Utilities and background processes
id ~ ^v --> VCL tests: execute VRT functions
Coverage for individual VMODs is in "${top_srcdir}vmod/tests".
bin/varnishtest/tests/d00025
.vtc
→
vmod/tests/directors_b00007
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00018
.vtc
→
vmod/tests/directors_c00003
.vtc
View file @
10e3b177
...
...
@@ -2,17 +2,17 @@ varnishtest "shard director/int key"
server s1 {
rxreq
txresp
-body "ech3Ooj"
txresp
} -start
server s2 {
rxreq
txresp
-body "ieQu2qua"
txresp
} -start
server s3 {
rxreq
txresp
-body "xiuFi3Pe"
txresp
} -start
varnish v1 -vcl+backend {
...
...
@@ -36,31 +36,26 @@ varnish v1 -vcl+backend {
}
sub vcl_recv {
if (req.url == "/1") {
set req.backend_hint = vd.backend(by=KEY, key=1);
}
if (req.url == "/2") {
set req.backend_hint = vd.backend(by=KEY, key=2147483647);
}
if (req.url == "/3") {
set req.backend_hint = vd.backend(by=KEY, key=4294967295);
}
set req.backend_hint = vd.backend(by=KEY, key=std.integer(req.http.key));
return(pass);
}
sub vcl_backend_response {
set beresp.http.backend = beresp.backend;
}
} -start
client c1 {
txreq -
url /1
txreq -
hdr "key: 1"
rxresp
expect resp.
body == "ech3Ooj"
expect resp.
http.backend == s1
txreq -
url /2
txreq -
hdr "key: 2147483647"
rxresp
expect resp.
body == "ieQu2qua"
expect resp.
http.backend == s2
txreq -
url /3
txreq -
hdr "key: 4294967295"
rxresp
expect resp.
body == "xiuFi3Pe"
expect resp.
http.backend == s3
} -run
bin/varnishtest/tests/d00029
.vtc
→
vmod/tests/directors_c00004
.vtc
View file @
10e3b177
varnishtest "shard director LAZY - d
18
.vtc"
varnishtest "shard director LAZY - d
irectors_c00003
.vtc"
server s1 -repeat 2 {
rxreq
...
...
bin/varnishtest/tests/d00019
.vtc
→
vmod/tests/directors_c00005
.vtc
View file @
10e3b177
...
...
@@ -2,17 +2,17 @@ varnishtest "shard director by req.url (default)"
server s1 {
rxreq
txresp
-body "ech3Ooj"
txresp
} -start
server s2 {
rxreq
txresp
-body "ieQu2qua"
txresp
} -start
server s3 {
rxreq
txresp
-body "xiuFi3Pe"
txresp
} -start
varnish v1 -vcl+backend {
...
...
@@ -31,19 +31,22 @@ varnish v1 -vcl+backend {
return(pass);
}
sub vcl_backend_response {
set beresp.http.backend = beresp.backend;
}
} -start
client c1 {
txreq -url /Boo0aixe
rxresp
expect resp.
body == "ech3Ooj"
expect resp.
http.backend == s1
txreq -url /eishoSu2
rxresp
expect resp.
body == "ieQu2qua"
expect resp.
http.backend == s2
txreq -url /Aunah3uo
rxresp
expect resp.
body == "xiuFi3Pe"
expect resp.
http.backend == s3
} -run
bin/varnishtest/tests/d00041
.vtc
→
vmod/tests/directors_c00006
.vtc
View file @
10e3b177
varnishtest "d
00017
.vtc but with weights"
varnishtest "d
irectors_c00005
.vtc but with weights"
server s1 {
rxreq
...
...
bin/varnishtest/tests/d0001
7.vtc
→
vmod/tests/directors_c0000
7.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00026
.vtc
→
vmod/tests/directors_c00008
.vtc
View file @
10e3b177
varnishtest "
shard director - same as d0001
7.vtc but setting backend in fetch"
varnishtest "
directors_c0000
7.vtc but setting backend in fetch"
server s1 {
rxreq
...
...
bin/varnishtest/tests/d00020
.vtc
→
vmod/tests/directors_c00009
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00015
.vtc
→
vmod/tests/directors_c00010
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00016
.vtc
→
vmod/tests/directors_c00011
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00021
.vtc
→
vmod/tests/directors_c00012
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00022
.vtc
→
vmod/tests/directors_c00013
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00023
.vtc
→
vmod/tests/directors_c00014
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00030
.vtc
→
vmod/tests/directors_c00015
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00024
.vtc
→
vmod/tests/directors_s00000
.vtc
View file @
10e3b177
File moved
bin/varnishtest/tests/d00039
.vtc
→
vmod/tests/directors_v00000
.vtc
View file @
10e3b177
File moved
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