TDD with nose or py.test

Lacrima lacrima.maxim at
Mon Nov 30 14:46:11 CET 2009


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 +
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