[MERGE] Use normalize_log to more accurately test blackbox log output.

Robert Collins robertc at robertcollins.net
Tue Nov 13 23:13:53 GMT 2007


On Wed, 2007-11-14 at 08:04 +0900, Kent Gibson wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> 
> 
> Robert Collins wrote:
> > On Tue, 2007-11-13 at 22:01 +0900, Kent Gibson wrote:
> >> -----BEGIN PGP SIGNED MESSAGE-----
> >> Hash: SHA1
> >>
> >> Since I've been poking around in the test_log recently I noticed
> one
> >> or two things that I felt could be improved.
> >>
> >> This probably isn't the "nice pattern matcher" that Robert Collins
> had
> >> in mind, 
> >
> > I had in mind hooking up doctest's logic which is very suitable.
> >
> Not familiar with it.  Do you think it be any easier to apply than
> normalisation?

Definitely. But thats a separate thing :).

> >> it is applying the log normaliser already used in
> >> tests/test_log to the blackbox log tests.
> >
> > Hmm. I think its good to get more code reuse. However looking at
> this it
> > appears that the actual output from the log reporter is completely
> > ignored.
> >
> > E.g. it could be printing complete garbage for the timestamp and we
> > wouldn't know because the normaliser just looks for the start of the
> > line, not the end.
> >
> That is a valid point for any of the normalised fields.
> However, you should note that none of the tests that use the
> normaliser are testing those fields.

Ok, that sounds alright then. 

bb:approve

-Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20071114/684bd27b/attachment.pgp 


More information about the bazaar mailing list