From e974d4fcf8404d53814b4559761f73dc2bc8a43a Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Tue, 17 Jan 2017 12:17:17 -0500 Subject: Exceptions have to be exceptions. #556 --- coverage/misc.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'coverage/misc.py') diff --git a/coverage/misc.py b/coverage/misc.py index b3b439c..534ef17 100644 --- a/coverage/misc.py +++ b/coverage/misc.py @@ -286,9 +286,9 @@ class ExceptionDuringRun(CoverageException): # unittest.SkipTest doesn't exist in Python 2.6. We backport it with # unittest2 in the coverage.py test suite. But for production, we don't need -# to derive from SkipTest, so if it doesn't exist, just use object. +# to derive from SkipTest, so if it doesn't exist, just use Exception. -class StopEverything(getattr(unittest, 'SkipTest', object)): +class StopEverything(getattr(unittest, 'SkipTest', Exception)): """An exception that means everything should stop. This derives from SkipTest so that tests that spring this trap will be -- cgit v1.2.1