[ANN] Metatest 0.1.0

Jonathan Fine jfine at pytex.org
Tue Sep 18 15:55:18 CEST 2007


Hello

This announcement also appears on the Metatest web site 
http://metatest.sourceforge.net

===
*** Metatest - a Python test framework

Metatest is a simple and elegant Python framework for writing tests.

Metatest is mostly about writing tests and by design is not tied to any 
particular test runner. Hence the name.

Here's how to write some tests using Metatest. We can think of the tests 
as an executable specification.

     from metatest.py.mymod import plus, Point

     # Function plus adds two numbers.
     plus(2, 2) == 4
     plus(2, '', _ex=TypeError)

     # Class Point represent a point in the plane.
     p = Point(2, 5)
     p.x == 2
     p.y == 5
     p.area == 10

And here's one way to run them.

     if __name__ == '__main__':
         import metatest
         metatest.run()

It's not hard to write an adapter that will run these tests in a 
different test runner framework.

We gave a talk about Metatest at PyCon UK 2007 and here are the slides 
(HTML).
     http://www.pyconuk.org
     http://metatest.sourceforge.net/doc/pyconuk2007/metatest.html

Please visit Sourceforge to download Metatest.
     http://sourceforge.net/project/showfiles.php?group_id=204046

-- 
Jonathan Fine



More information about the Python-announce-list mailing list