From f818faf7b7fd4f9dc5794e35e2515c95b011cc3e Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 17 Mar 2007 02:47:09 +0000 Subject: Fix broken exception handling. svn path=/main/trunk/; revision=6223 --- pym/portage/tests/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pym') diff --git a/pym/portage/tests/__init__.py b/pym/portage/tests/__init__.py index 7d13af1e6..bef41ef03 100644 --- a/pym/portage/tests/__init__.py +++ b/pym/portage/tests/__init__.py @@ -3,7 +3,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -import os, unittest, time +import os, sys, time, unittest import portage.tests def main(): @@ -110,10 +110,10 @@ class TestCase(unittest.TestCase): result.addTodo(self,"%s: TODO" % testMethod) else: result.addFailure(self, self._exc_info()) - except KeyboardInterrupt: + except (KeyboardInterrupt, SystemExit): raise except: - result.addError(self, self._exc_info()) + result.addError(self, sys.exc_info()) try: self.tearDown() except KeyboardInterrupt: -- cgit v1.2.3-1-g7c22