[liblouis-liblouisxml] Re: Testing python bindings

  • From: Christian Egli <christian.egli@xxxxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Thu, 11 Feb 2010 16:40:53 +0100

Michael Whapples <mwhapples@xxxxxxx> writes:

> Python offers doctest and unittest by default and what's more doctests
> can be made to integrate with unittest so we don't really need to go
> only one way. Doctest is good as it can be included in docs
> (docstrings or text files, may be other types of file) so show working
> examples but I guess that we don't want all tests in doctest as to
> test things really thoroughly there may be more than needed or wanted
> in a doc.

I think for now doctests are probably good enough, as they alse serve as
a sort of documentation on the proper usage.

> I haven't a clue how this could be integrated into the existing test
> system, but it can be made that you just run a python script and
> results are printed to the screen (may be it could change the exit
> code as well).

If invoking "python __init.py__" is all there is to it then this can
easily be achieved from the Makefile. We just need to make sure that we
do not hard code this as a build time requirement. People that do not
use the Python interface also do not want to test it. We will have
configure to check for Python and only then do the tests for the Python
interface. 

Thanks
Christian
-- 
Christian Egli
Swiss Library for the Blind, Visually Impaired and Print Disabled
Grubenstrasse 12, CH-8045 Zürich, Switzerland
For a description of the software and to download it go to
http://www.jjb-software.com

Other related posts: