[Python-checkins] cpython (3.5): #25687: clarify that errors in tearDown increase the total number of reported

ezio.melotti python-checkins at python.org
Sun Mar 13 03:42:52 EDT 2016


https://hg.python.org/cpython/rev/cecd39887faa
changeset:   100510:cecd39887faa
branch:      3.5
parent:      100508:b9256d5f1ab4
user:        Ezio Melotti <ezio.melotti at gmail.com>
date:        Sun Mar 13 09:40:09 2016 +0200
summary:
  #25687: clarify that errors in tearDown increase the total number of reported errors.  Initial patch by HyeSoo Park.

files:
  Doc/library/unittest.rst |  10 ++++++----
  Misc/ACKS                |   1 +
  2 files changed, 7 insertions(+), 4 deletions(-)


diff --git a/Doc/library/unittest.rst b/Doc/library/unittest.rst
--- a/Doc/library/unittest.rst
+++ b/Doc/library/unittest.rst
@@ -680,10 +680,12 @@
       Method called immediately after the test method has been called and the
       result recorded.  This is called even if the test method raised an
       exception, so the implementation in subclasses may need to be particularly
-      careful about checking internal state.  Any exception, other than :exc:`AssertionError`
-      or :exc:`SkipTest`, raised by this method will be considered an error rather than a
-      test failure.  This method will only be called if the :meth:`setUp` succeeds,
-      regardless of the outcome of the test method. The default implementation does nothing.
+      careful about checking internal state.  Any exception, other than
+      :exc:`AssertionError` or :exc:`SkipTest`, raised by this method will be
+      considered an additional error rather than a test failure (thus increasing
+      the total number of reported errors). This method will only be called if
+      the :meth:`setUp` succeeds, regardless of the outcome of the test method.
+      The default implementation does nothing.
 
 
    .. method:: setUpClass()
diff --git a/Misc/ACKS b/Misc/ACKS
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -1087,6 +1087,7 @@
 Peter Parente
 Alexandre Parenteau
 Dan Parisien
+HyeSoo Park
 William Park
 Claude Paroz
 Heikki Partanen

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list