[Python-checkins] r70562 - python/trunk/Doc/library/unittest.rst
benjamin.peterson
python-checkins at python.org
Tue Mar 24 00:13:36 CET 2009
Author: benjamin.peterson
Date: Tue Mar 24 00:13:36 2009
New Revision: 70562
Log:
forgot to document that setUp can be skipped (silly me...)
Modified:
python/trunk/Doc/library/unittest.rst
Modified: python/trunk/Doc/library/unittest.rst
==============================================================================
--- python/trunk/Doc/library/unittest.rst (original)
+++ python/trunk/Doc/library/unittest.rst Tue Mar 24 00:13:36 2009
@@ -455,6 +455,9 @@
def test_not_run(self):
pass
+:meth:`TestCase.setUp` can also skip the test. This is useful when a resource
+that needs to be set up is not available.
+
Expected failures use the :func:`expectedFailure` decorator. ::
class ExpectedFailureTestCase(unittest.TestCase):
@@ -569,8 +572,8 @@
.. method:: skip(reason)
- Skips the current test. See :ref:`unittest-skipping` for more
- information.
+ Calling this during the a test method or :meth:`setUp` skips the current
+ test. See :ref:`unittest-skipping` for more information.
.. method:: debug()
More information about the Python-checkins
mailing list