TDD with nose or py.test

Lacrima lacrima.maxim at gmail.com
Mon Nov 30 08:46:11 EST 2009


Hello!

I am learning TDD with Python and there is not much information about
this topic. Python is shipped with unittest module. That is fine, but
I also discovered other libraries: nose and py.test. They promise to
make life yet easier for a developer. But I still can't figure out,
which combination I should use them in.
Nose seems simpler than py.test, but py.test offers more features. And
both py.test and nose say that they do not replace unittest module,
but extend it.
So as I understand my choice should be nose + unittest, or py.test +
unittest.
And now I'd like to hear about best practices in TDD in Python. Maybe
not best practices, but basic approach.
So which tests should I write with unittest, which with nose or
py.test? How should I combine them?

I am learning Python and I need your advice.
Thanks in advance.

Sorry if my English isn't very proper



More information about the Python-list mailing list