[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Support regex in EXPECTED ERR list

From: Ben Reser <ben_at_reser.org>
Date: Wed, 23 Jan 2013 08:04:43 -0800

On Wed, Jan 23, 2013 at 2:54 AM, Bert Huijben <bert_at_qqmail.nl> wrote:
>
> I think you should be able to do this without your patch if you use
>
> expected_err = svntest.verify.RegexOutput([
> # lines here
> ])
>
> Instead of
> expected_err = [
> # lines here
> ]
>
> Just like how we handle separate kinds of output (items, unordered, regex,
> unordered regex, any text, or a plain list)

Nope it would be:
svntest.verify.RegexOutput('regexhere', match_all=False)

Note that you get ONE regex. Unless you pass the match_all=False then
that regex must match every line of output. If you do pass
match_all=False then as soon as it matches any line of the output then
it is considered successful.

I haven't looked at his patch but something that allows you to provide
a list of regex's that matches one regex against each line might be
nice.

I was working on a test just yesterday where I actually verified
output twice because I wanted to check two lines and didn't want to
match exact output.
Received on 2013-01-23 17:05:24 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.