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
4d446f43
Commit
4d446f43
authored
Feb 04, 2017
by
Dridi Boukelmoune
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't logexpect partial regular expressions
It turns out some of the tests weren't completely checked.
parent
03f65b10
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
12 deletions
+17
-12
b00002.vtc
bin/varnishtest/tests/b00002.vtc
+4
-4
r01441.vtc
bin/varnishtest/tests/r01441.vtc
+5
-5
s00004.vtc
bin/varnishtest/tests/s00004.vtc
+1
-1
vtc_logexp.c
bin/varnishtest/vtc_logexp.c
+7
-2
No files found.
bin/varnishtest/tests/b00002.vtc
View file @
4d446f43
...
...
@@ -18,10 +18,10 @@ varnish v1 -vcl+backend {
# last header and VCL_return b deliver
logexpect l1 -v v1 -g request {
expect * 1002 Begin
expect * = BerespHeader
^Date:
expect 0 = VCL_call
^BACKEND_RESPONSE
expect 0 = BerespHeader
^x-ttl: 0.000
expect 0 = VCL_return
^deliver
expect * = BerespHeader
{^Date:}
expect 0 = VCL_call
{^BACKEND_RESPONSE}
expect 0 = BerespHeader
{^x-ttl: 0.000}
expect 0 = VCL_return
{^deliver}
} -start
client c1 {
...
...
bin/varnishtest/tests/r01441.vtc
View file @
4d446f43
...
...
@@ -19,15 +19,15 @@ varnish v1 -vcl+backend {
} -start -cliok "param.set debug +syncvsl"
logexpect l1 -v v1 -g session {
expect 0 1000 Begin
sess 0 HTTP/1
expect 0 1000 Begin
{sess 0 HTTP/1}
expect * = End
expect 0 1001 Begin
req 1000 rxreq
expect 0 1001 Begin
{req 1000 rxreq}
expect * = End
expect 0 1002 Begin
bereq 1001 fetch
expect 0 1002 Begin
{bereq 1001 fetch}
expect * = End
expect 0 1003 Begin
req 1001 esi
expect 0 1003 Begin
{req 1001 esi}
expect * = End
expect 0 1004 Begin
bereq 1003 fetch
expect 0 1004 Begin
{bereq 1003 fetch}
expect * = End
} -start
...
...
bin/varnishtest/tests/s00004.vtc
View file @
4d446f43
...
...
@@ -39,7 +39,7 @@ logexpect l1 -v v1 -g request {
expect * = Timestamp {Beresp: \S+ 1\.\d+ [01]\.\d+}
expect * = Timestamp {BerespBody: \S+ 2\.\d+ 1\.\d+}
expect * = End
expect 0 1003 Begin
req 1001 restart
expect 0 1003 Begin
{req 1001 restart}
expect * = Timestamp {Start: \S+ 2\.\d+ 0\.\d+}
expect * = Timestamp {Process: \S+ 2\.\d+ 0\.\d+}
expect * = Timestamp {Resp: \S+ 2\.\d+ 0\.\d+}
...
...
bin/varnishtest/vtc_logexp.c
View file @
4d446f43
...
...
@@ -101,8 +101,10 @@
* Tag to match against
*
* regex:
* regular expression to match against (optional) ('*' is anything, '='
* is the value of the last matched record)
* regular expression to match against (optional)
*
* For skip, vxid and tag, '*' matches anything, '=' expects the value of the
* previous matched record.
*/
#include "config.h"
...
...
@@ -433,6 +435,9 @@ cmd_logexp_expect(CMD_ARGS)
if
(
av
[
1
]
==
NULL
||
av
[
2
]
==
NULL
||
av
[
3
]
==
NULL
)
vtc_fatal
(
vl
,
"Syntax error"
);
if
(
av
[
4
]
!=
NULL
&&
av
[
5
]
!=
NULL
)
vtc_fatal
(
vl
,
"Syntax error"
);
if
(
!
strcmp
(
av
[
1
],
"*"
))
skip_max
=
LE_ANY
;
else
{
...
...
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