Author dmaurer
Recipients dmaurer
Date 2019-04-20.09:20:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Currently, "" supports several features to control testing - among others, a test can be skipped via the attribute "__unittest_skip__". "TestCase.debug" ignores all those controls and calls the test method unconditionally.

I am using "zope.testrunner" to run test suites. Its "-D" option switches from "" to "TestCase.debug" in order to allow the analysis of the state of a failing test in the Python debugger. "-D" is typically used if a test in a larger suite failed and a detailed analysis is required to determine the failure's cause. It is important that this second run executes the same tests as the first run; it is not helpful when the second run fails in a test skipped in the first run. Therefore, "TestCase.debug" should honour all test controls supported by  "".

One could argue that the testsuite runner should implement this logic. However, this would force the runner to duplicate the test control logic using internal implementation details of "unittest". Conceptually, it is much nicer to have the test control encapsulated by "unittest".
Date User Action Args
2019-04-20 09:20:54dmaurersetrecipients: + dmaurer
2019-04-20 09:20:54dmaurersetmessageid: <>
2019-04-20 09:20:54dmaurerlinkissue36674 messages
2019-04-20 09:20:54dmaurercreate