Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use TextTestRunner class from Python unittest module in failfast mode?

All I found in documentation of unittest module is description of TextTestRunner's constructor and the following sample code using its run() method: unittest.TextTestRunner(verbosity=2).run(suite)

I would like to know how I can use TextTestRunner in failfast mode.

like image 951
Piotr Dobrogost Avatar asked Nov 09 '11 16:11

Piotr Dobrogost


1 Answers

Constructor of TextTestRunner class has failfast parameter which is not shown in the constructor's documentation.

UPDATE

I raised bug 17871 and it's fixed now what you can verify at http://docs.python.org/3.3/library/unittest.html#unittest.TextTestRunner

like image 164
Piotr Dobrogost Avatar answered Oct 05 '22 11:10

Piotr Dobrogost