Is it possible to use python to unit test C++ code?

keirr keir.robinson at gmail.com
Wed Dec 21 10:28:00 EST 2005


sylcheung at gmail.com wrote:
> Is it possible to use python to unit test C++ code? If yes, is there
> any example available?
>

If I had to use python to test C++ code, I'd use the Boost python
library: http://www.boost.org/libs/python/doc/ to expose my C++
classes, and write the unittests in python after importing the wrapped
C++ code.
Note, you did ask if it was possible.  Is it advisable?  That's another
question.

All the best,

 Keir.




More information about the Python-list mailing list