Bug 4559 - create a message parser test suite
create a message parser test suite
Status: NEW
Product: Spamassassin
Classification: Unclassified
Component: Regression Tests
3.1.0
Other other
: P5 enhancement
: Future
Assigned To: SpamAssassin Developer Mailing List
:
Depends on:
Blocks: 4560
  Show dependency tree
 
Reported: 2005-08-26 09:44 UTC by Justin Mason
Modified: 2006-12-31 12:50 UTC (History)
0 users



Attachment Type Modified Status Actions Submitter/CLA Status

Note You need to log in before you can comment on or make changes to this bug.
Description Justin Mason 2005-08-26 09:44:56 UTC
Every now and again, we come up against bugs in our message parser (MIME, HTML,
headers, base64/qp decoding, etc. etc.)  We fix them, but occasionally there's
regressions.  Funnily enough, that's why regression test suites were invented! ;)

So this bug is a reminder that we need to implement a regression test suite for
our message parser, something like "t/messageparser.t".  

I envisage it as using a vast collection of message files, something like a
mass-check corpus.  I don't think it's necessary to distribute these message
files, they could be in SVN only, in order not to bloat the distribution tarball
with unnecessary tests.
Comment 1 Theo Van Dinter 2005-08-26 10:58:25 UTC
Subject: Re:   New: create a message parser test suite

On Fri, Aug 26, 2005 at 09:44:56AM -0700, bugzilla-daemon@bugzilla.spamassassin.org wrote:
> So this bug is a reminder that we need to implement a regression test suite for
> our message parser, something like "t/messageparser.t".  
> 
> I envisage it as using a vast collection of message files, something like a
> mass-check corpus.  I don't think it's necessary to distribute these message
> files, they could be in SVN only, in order not to bloat the distribution tarball
> with unnecessary tests.

It's worth noting that we already have t/mimeparse.t to cover some of these,
but not all obviously.  I don't think there's really an issue distributing the
messages, I actually think the rule can just generate them and throw through
parse() to get the output.  I've typically been doing some form of "parse
this, then verify the correct internal part layout and sha1sum outputs",
though there are likely other/better ways to do it.