[PATCH] logexpect only attempts regex matches for matching tags

Geoff Simmons geoff at uplex.de
Thu Oct 10 11:59:45 CEST 2013


Hello all,

Sorry about that empty mail.

While trying to learn to use logexpect, I noticed that for expectations
like these:

expect 0 * FixedTag
expect * = FooTag reg.x*

... it would attempt the regex match for every log entry after the
FixedTag, regardless of whether the entry has the FooTag. It continues
until it hits an entry with a match, which may or may not have the FooTag.

I may have misunderstood the intention here, but the attached patch
ensures that the regex match is only attempted for log entries with the
expected tag.


Best,
Geoff
-- 
** * * UPLEX - Nils Goroll Systemoptimierung

Scheffelstraße 32
22301 Hamburg

Tel +49 40 2880 5731
Mob +49 176 636 90917
Fax +49 40 42949753

http://uplex.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-varnishtest-logexpect-only-attempts-regex-matches-fo.patch
Type: text/x-patch
Size: 820 bytes
Desc: not available
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-dev/attachments/20131010/cdefaf11/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 900 bytes
Desc: OpenPGP digital signature
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-dev/attachments/20131010/cdefaf11/attachment.pgp>


More information about the varnish-dev mailing list