Jason Pyeron:
> > -----Original Message-----
> > From: Wietse Venema
> > Sent: Wednesday, September 29, 2021 6:51 AM
> > 
> > Jason Pyeron:
> > > Is there a readme or other documentation on running the tests?
> > 
> > Nope. Tests have no formal structure. I'm thinking of making the
> > tests more systematical when I have time, maybe later next year.
> 
> So basically each test is its own documentation then?

The tests are ad-hoc code. There is no documentation.

> > > It appears the tests assume postfix is installed prior
> > 
> > It is a long time since I did not have Postfix installed on my
> > development system(s). Again, easy enough to make the tests more
> > hermetic. It just takes some time.
> 
> I would be interested in helping.

I have good experiences with Gtest (as part of my job) and would
like to port Postfix tests over to that where possible.

This is easiest for the few Postfix modules that have no dependencies.

For things that have dependencies outside Postfix, or that have
complex dependencies within Postfix, this requires implementing
mocks that provide a controlled environment for the thing being
tested, i.e. mock vstream, mock msg, mock libdns, mock xsasl, mock
logging, perhaps mock SMTP. That stuff just was not available 25
years ago. 

        Wietse

Reply via email to